Search results for query "sapiro"
- 5709 messages

[MM3-users] Re: Permission denied for fulltext_index
by Jan Eden
On 2022-11-27 19:36, Jan Eden wrote:
> On 2022-11-27 08:01, Mark Sapiro wrote:
> > On 11/27/22 00:35, Jan Eden via Mailman-users wrote:
> > >
> > > – but the existing directory /opt/mailman/fulltext_index (and its
> > > contents) are readable and writeable by mailman:mailman:
> > >
> > > > drwxrwxr-x 2 mailman mailman 4096 Nov 27 08:00 fulltext_index/
> > > >
> > > > -rw-rw-r-- 1 mailman mailman 4473 Nov 27 08:00 _MAIN_65.toc
> > > > -rw-rw-r-- 1 mailman mailman 15456 Nov 27 08:00 MAIN_bc0cs2aohovftat6.seg
> > > > -rw-rw-r-- 1 mailman mailman 15454 Nov 27 06:00 MAIN_brbo8i8edmlz0za4.seg
> > > > -rw-rw-r-- 1 mailman mailman 15462 Nov 27 07:00 MAIN_ewnemc7lsnodd3y7.seg
> > > > -rw-rw-r-- 1 mailman mailman 157324 Nov 27 04:00 MAIN_qag60g1rrumshtc2.seg
> > > > -rw-rw-r-- 1 mailman mailman 15459 Nov 27 05:00 MAIN_w6e0ohurasusy61d.seg
> > > > -rwxrwxr-x 1 mailman mailman 0 Nov 24 16:00 MAIN_WRITELOCK*
> > >
> > > I fail to see where haystack tries (and fails) to create the directory.
> > > FWIW, deleting threads is not a problem.
> >
> > It is uwsgi trying to do this. What user is it running as? Maybe you need to
> > add that user to the `mailman` group.
>
> That's what baffles me – uwsgi is run as the mailman user:
>
> mailman 3904667 1.3 0.5 129516 62188 ? Ss 18:33 0:00 /opt/mailman/venv/bin/uwsgi --ini /etc/mailman3/uwsgi.ini
> mailman 3904668 0.0 0.3 203248 48796 ? Sl 18:33 0:00 /opt/mailman/venv/bin/uwsgi --ini /etc/mailman3/uwsgi.ini
> mailman 3904670 0.8 0.6 220436 74464 ? Sl 18:33 0:00 /opt/mailman/venv/bin/uwsgi --ini /etc/mailman3/uwsgi.ini
I tried setting permissions on /opt/mailman/fulltext_index to 777
temporarily, but the issue remained (as expected). It occurs in the
Whoosh backend of Haystack (whoosh_backend.py, line 132-133):
> if self.use_file_storage and not os.path.exists(self.path):
os.makedirs(self.path)
where self.path is referenced, which is defined in line 110 (as part of
the __init__ function):
> def __init__(self, connection_alias, **connection_options):
> super().__init__(connection_alias, **connection_options)
> self.setup_complete = False
> self.use_file_storage = True
> self.post_limit = getattr(connection_options, "POST_LIMIT", 128 * 1024 * 1024)
> self.path = connection_options.get("PATH")
Unfortunately, I cannot see where the PATH key for connection_options is
defined.
- Jan
2 years, 7 months

[MM3-users] Re: Hyperkitty download mbox
by Andrew Hodgson
Mark Sapiro wrote:
>On 4/25/21 2:20 PM, Andrew Hodgson wrote:
>> Hi,
>>
>> Hyperkitty 1.3.4.
>>
>> I am trying to download a complete list mbox by going to all threads view and using the download option. I have tried a couple of tools (Gunzip and Winrar) and both are giving me an unexpected end of file when trying to decompress the gz file.
[...]
>Depending in the web server configuration, timeouts can occur when downloading large archive mboxes. instead of downloading the entire mbox with <https://lists.hodgsonfamily.org/hyperkitty/list/plextalk@lists.hodgsonfamil…>,
>do it in pieces by adjusting start and end. e.g.
[...]
>Although, I don't think timing out is the issue, and I'm not sure what is, but I think it has something to do with messages in the archive. If I try to get the 3 pieces as above, the first piece with
start=2008-02-19&end=2012-12-31 works but the others don't and even the smaller
Yep there is a problem with an imported mbox which seems to be present somewhere in the archive on all the lists which I imported using that method. Here is a recent trace from the download option:
[2021-04-26 08:53:12 +0000] [28181] [ERROR] Error handling request
Traceback (most recent call last):
File "/opt/mailman/venv/lib/python3.7/site-packages/gunicorn/workers/sync.py", line 180, in handle_request
for item in respiter:
File "/opt/mailman/venv/lib/python3.7/site-packages/hyperkitty/views/mlist.py", line 335, in stream_mbox
msg = email.as_message()
File "/opt/mailman/venv/lib/python3.7/site-packages/hyperkitty/models/email.py", line 178, in as_message
msg["Message-ID"] = "<%s>" % self.message_id
File "/usr/lib/python3.7/email/message.py", line 409, in __setitem__
self._headers.append(self.policy.header_store_parse(name, val))
File "/usr/lib/python3.7/email/policy.py", line 145, in header_store_parse
raise ValueError("Header values may not contain linefeed "
ValueError: Header values may not contain linefeed or carriage return characters
I do still have the original mbox files for the imported lists which were on Mailman 2.1. The other thing is when downloading these mbox files I noticed they aren't the raw messages as we had in Mailman 2.1 but modified with headers stripped and email addresses modified. Is there any way to get the raw mbox back as in the option we had in Mailman 2.1?
Thanks.
Andrew.
4 years, 2 months

[MM3-users] Re: Fwd: [Django] ERROR (EXTERNAL IP): Internal Server Error: /mailman3/hyperkitty/api/mailman/archive
by David Partain
On Thu, 2021-02-25 at 13:24 -0800, Mark Sapiro wrote:
On 2/25/21 6:32 AM, David Partain via Mailman-users wrote:
In /etc/mailman3/mailman.cfg I see:
class: mailman.database.mysql.MySQLDatabase
url: mysql+pymysql://mailman3:NopeNotPastingThat@localhost/mailman3?charset=utf8&use_unicode=1
Should I change the latter to be something like:
url: mysql+pymysql://mailman3:NopeNotPastingThat@localhost/mailman3?charset=utf8mb4&use_unicode=1
Yes, either make it charset=utf8mb4 or I think dropping the charset=
option altogether will use the database default, however I'm not clear
why this would be the issue as this only controls how Mailman core
accesses the database, and your issue is with HyperKitty/Django and its
access is controlled by the DATABASES setting in Django's settings which
you say do specify 'charset': 'utf8mb4' in OPTIONS.
Also, it seems Mailman core is not even using the same database - i.e.
`mailman3` whereas Django's is `mailman3web`.
Hi Mark,
Thanks for being patient with me. I'm still baffled but might have found the problem.
I've done the above, to no avail.
If I look at the queries being sent to mysql, I see stuff like this:
174 Connect mailman3web@localhost<mailto:mailman3web@localhost> on mailman3web using TCP/IP
174 Query SET sql_mode='STRICT_TRANS_TABLES'
174 Query COMMIT
174 Query SET AUTOCOMMIT = 0
174 Query SET AUTOCOMMIT = 1
174 Query SET AUTOCOMMIT = 0
I note that there is nothing about the charset, so something's clearly wonky.
As previously stated, /etc/mailman3/mailman-web.py has the right thing:
'OPTIONS': {
'init_command': "SET sql_mode='STRICT_TRANS_TABLES'",
'charset': 'utf8mb4',
},
but that latter is having no effect.
I then found /var/lib/ucf/cache/:etc:mailman3:mailman-web.py which doesn't have charset
(but does have init_command), but I _think_ that's only about the package management system.
So... I found that /usr/share/mailman3-web/settings_local.py is just a link to /etc/mailman3/mailman-web.py
(which obviously has the right thing), but what about the .pyc file?
# grep -i STRICT_TRANS_TABLES /usr/share/mailman3-web/settings_local.pyc
Binary file /usr/share/mailman3-web/settings_local.pyc matches
# grep -i charset /usr/share/mailman3-web/settings_local.pyc
#
It ain't in the .pyc file. Am I overly optimistic that that might the be problem?
If so, I'd be grateful if someone'd tell the newbie how to recreate that file without
trashing something.
Cheers,
David
4 years, 4 months

[MM3-users] Re: FILTER_VHOST = True doesn't work fine with alias_domain
by Élodie BOSSIER
Thank you for your response Mark,
With Mailman 2.1, the lists were split on their webpage respectively.
How could I do same with Mailman 3.3.3 (Tom Sawyer) please ?
My domain table SQL have this result :
id, mail_host, description, alias_domain
1, ml.franceserv.fr, NULL, local.ml.franceserv.fr
2, ml.viticreation.fr, NULL, local.ml.viticreation.fr
mailinglist table SQL :
id, list_name, mail_host, list_id, ...
1, bar, ml.franceserv.fr, bar.ml.franceserv.fr, ...
2, viticreation, ml.viticreation.fr, viticreation.ml.viticreation.fr, ...
Can I do something ? A patch somewhere ? Shall I wait issues are solved
and how long approximatively please ?
Which don't reassure me is I can see old discussions about FILTER_VHOST
there are 2 years.
I can retrieve my own old question there are 2 years when I tried to
migrate from Mailman 2 to Mailman 3 :
https://lists.mailman3.org/archives/list/mailman-users@mailman3.org/thread/…
and in 2020 you told me it was working for you at this date. It's don't
reassure me to retrieve a problem I got there are 2 years.
I could set in production my Mailman 3 but the problem is my customers
won't understand why they can see the lists of others domains name ...
and not sure about the security ...
Thank you again.
Le 18/02/2022 à 00:33, Mark Sapiro a écrit :
> There are issues with FILTER_VHOST due to the fact that mailing lists
> do not have a web host attribute. This means when you go to HyperKitty
> or Postorius when FILTER_VHOST is True, we look up the domain record
> for the web host you are visiting and show you all the lists whose
> mail host matches the mail host for the web host domain. This has
> nothing to do with alias domains.
>
> What that means is if all your domains records have a unique mail
> host, FILTER_VHOST will work as you expect, but if multiple domains
> have the same mail host FILTER_VHOST will show you the lists for the
> current web host plus all those with a matching mail host.
>
> I.e. if in your case, the ml.franceserv.fr domain and the
> ml.viticreation.fr domain have the same mail host, FILTER_VHOST won't
> separate them. If they have different mail hosts FILTER_VHOST will
> separate them.
>
3 years, 4 months

[MM3-users] Re: Wrong info in moderation mail when held due to match of a header rule
by tlhackque
On 17-Oct-20 14:31, Mark Sapiro wrote:
> On 10/17/20 10:39 AM, Torge Riedel wrote:
>> The message is being held because:
>>
>> Header "Yes" matched a header rule
>>
>> At your convenience, visit your dashboard to approve or deny the
>> request.
>>
>> I think this is wrong, it should read 'Header "x-spam" matched a header
>> rule'. Cause the header rule is configured for header "x-spam" and
>> pattern "Yes".
>
> The message is defined as
>
> 'Header "{}" matched a header rule'
>
> where {} is replaced with the value of the matching header. I agree it
> would be better if it were something like
>
> 'Header value "{}" matched a header rule for {}:'
>
> with {}s replaced with the header value and name. That would make it in
> your case
>
> 'Header value "Yes" matched a header rule for x-spam:'
>
>> I haven't found a bug report for this yet on gitlab. If someone of the
>> developers confirm this is wrong, I will file a bug on gitlab for it.
>
> Please do file a bug. It won't be fixed until after the upcoming 3.3.2
> final release because we not making i18n changes between the candidate
> and final releases. Also, if you don't like my suggestion, feel free to
> suggest something else.
>
FWIW, I suggest:
Header "{name}": rule matched value "{value}"
Name tends to be short and must be simple ASCII. Value can be very long
and encoded, so it may wrap. Name will be short and recognizable. Plus
the name provides the context for the value - and name:value is the way
the header appears in the e-mail. So I think name before value obeys
the UI principle of least surprise.
I might also add the rule number or config filename:line, as in
Header "{name}": rule in {file}:{n} matched value "{value}"
This would be helpful when backtracking from a rejected message to the
cause.
A sample expansion might be:
Header "X-Spam": rule in foo.conf:83 matched value "yes"
4 years, 8 months

[MM3-users] Re: A little stuck with installation of MM3 - ModuleNotFoundError: No module named 'flufl.lock'
by Abhilash Raj
On Sat, Jul 25, 2020, at 2:17 PM, Mark Sapiro wrote:
> On 7/25/20 12:54 PM, Odhiambo Washington wrote:
> >
> > Finally, I have adapted your init script to get some rudimentary one that I
> > could use on FreeBSD.
> > I have to change /opt/mailman to be owned by mailman3:mailman3 (because I
> > have "live" MLs on this server, using mailman-2.1.34.
> > I am not sure if they can co-exist. I suppose they could, but what might be
> > the security implication, if any??
>
> I manage more than one server that supports both Mailman 2.1 and Mailman
> 3 running as user `mailman`. I'm not aware of any security issues.
>
>
> > This is what the init script looks like (rudimentary!!):
> > (venv) [root@gw /usr/local/etc/rc.d]# less mailman3
> > ### BEGIN INIT INFO
> > # Provides: GNU Mailman
> > # Short-Description: Mailman3 Service
> > # Description: service control for Mailman3
> > ### END INIT INFO
> >
> > PATH=/opt/mailman/mm/bin:/opt/mailman/mm/venv/bin:/usr/sbin:/usr/bin:/bin:/sbin:
> > DESC="GNU Mailman service"
> > DAEMON=/opt/mailman/mm/bin/mailman
> > NAME=mailman
> > USER=mailman3
> > GROUP=mailman3
> >
> > # Needed by click
> > export LANG=en_US.UTF-8
> >
> > # Exit if the package is not installed
> > [ -x "$DAEMON" ] || exit 0
> >
> > # Load the VERBOSE setting and other rcS variables
> > #. /lib/init/vars.sh
> >
> > # Define LSB log_* functions.
> > # Depend on lsb-base (>= 3.2-14) to ensure that this file is present
> > # and status_of_proc is working.
> > #. /lib/lsb/init-functions
> >
> > case "$1" in
> > start)
> > [ "$VERBOSE" != no ] && echo "Starting $DESC" "$NAME"
> > # use --force to remove a stale lock.
> > /usr/local/bin/sudo -u $USER $DAEMON start --force
>
> T don't recommend using --force in init scripts. It *shouldn't* matter
> because even with --force the master shouldn't break the lock if the pip
> that set it still exists, but I prefer not to use it.
>
>
> > ;;
> > stop)
> > [ "$VERBOSE" != no ] && echo "Stopping $DESC" "$NAME"
> > /usr/local/bin/sudo -u $USER $DAEMON stop
> > ;;
> > status)
> > /usr/local/bin/sudo -u $USER $DAEMON status
> > ;;
> > reopen)
> > /usr/local/bin/sudo -u $USER $DAEMON reopen
> > ;;
> > restart)
> > log_daemon_msg "Restarting $DESC" "$NAME"
> > /usr/local/bin/sudo -u $USER $DAEMON restart
> > ;;
> > *)
> > echo "Usage: $SCRIPTNAME {start|stop|status|reopen|restart}" >&2
> > exit 3
> > ;;
> > esac
> >
> > It does start mailman3 for sure, but also complains after a few seconds
> > with the message:
> >
> > (venv) [root@gw /usr/local/etc/rc.d]#
> > */opt/mailman/mm/venv/lib/python3.7/site-packages/mailman-3.3.2b1-py3.7.egg/mailman/rest/wsgiapp.py:180:
> > DeprecatedWarning: Call to deprecated function __init__(...). API class may
> > be removed in a future release, use falcon.App instead.*
> > * **kws)*
>
>
> Hmm... strange, My various MM 3 installs are running falcon 1.4.0, 2.0.0
> and 3.0.0a1 and I don't see this warning, but it is only a deprecation
> warning. It doesn't mean it won't work.
I have seen this during development and there is an issue open for this[1].
[1]: https://gitlab.com/mailman/mailman/-/issues/733
>
>
> > But:
> >
> > (venv) [root@gw /usr/local/etc/rc.d]# ps ax | grep mailman
> ...
>
> It seems Mailman core and the rest runner and its workers are all running.
>
>
> >
> > Assuming that I am using mod_wsgi with Apache, and that I have configured
> > apache right using
> > https://wiki.list.org/DOC/Mailman%203%20installation%20experience?action=At…
> > ..
> > should I be able to access the MM3 web UI??
>
> Yes, I think so.
>
>
> > At that point, I am feeling somewhat confused as to what to try next.
> >
> > (venv) [root@gw /opt/mailman/mm/var/logs]# less mailman.log
> > Jul 25 22:53:16 2020 (40670) Master started
> > Jul 25 22:53:18 2020 (42036) bounces runner started.
> > Jul 25 22:53:18 2020 (45205) out runner started.
> > Jul 25 22:53:19 2020 (41191) archive runner started.
> > Jul 25 22:53:19 2020 (46670) retry runner started.
> > Jul 25 22:53:19 2020 (44567) nntp runner started.
> > Jul 25 22:53:19 2020 (43069) in runner started.
> > Jul 25 22:53:19 2020 (46960) virgin runner started.
> > Jul 25 22:53:20 2020 (45720) pipeline runner started.
> > Jul 25 22:53:20 2020 (47326) digest runner started.
> > Jul 25 22:53:20 2020 (43755) lmtp runner started.
> > Jul 25 22:53:20 2020 (45922) rest runner started.
> > [2020-07-25 22:53:20 +0300] [45922] [INFO] Starting gunicorn 20.0.4
> > [2020-07-25 22:53:20 +0300] [45922] [INFO] Listening at:
> > http://127.0.0.1:8001 (45922)
> > [2020-07-25 22:53:20 +0300] [45922] [INFO] Using worker: sync
> > [2020-07-25 22:53:20 +0300] [54732] [INFO] Booting worker with pid: 54732
> > [2020-07-25 22:53:20 +0300] [55467] [INFO] Booting worker with pid: 55467
> > Jul 25 22:53:21 2020 (42743) command runner started.
>
>
> The above is all fine, but it is just Mailman core.
>
>
> > How do I access the web UI for MM3 now?
>
>
> The Apache config points to /opt/mailman/mm/wsgi.py, a sampole of which
> is at
> <https://wiki.list.org/DOC/Mailman%203%20installation%20experience?action=At…>.
> Do you have that?
>
> If you installed the Apache config literally, the location for Mailman 3
> is defined by
> <https://wiki.list.org/DOC/Mailman%203%20installation%20experience?action=At…>
> and the URL would be http(s)://your.server/mm3 - have you tried that?
>
> --
> Mark Sapiro <mark(a)msapiro.net> The highway is for gamblers,
> San Francisco Bay Area, California better use your sense - B. Dylan
> _______________________________________________
> Mailman-users mailing list -- mailman-users(a)mailman3.org
> To unsubscribe send an email to mailman-users-leave(a)mailman3.org
> https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/
>
--
thanks,
Abhilash Raj (maxking)
4 years, 11 months

[MM3-users] Re: Problem updating mailman
by Odhiambo Washington
On Sun, 24 Jan 2021 at 00:46, Mark Sapiro <mark(a)msapiro.net> wrote:
> On 1/23/21 2:56 AM, Odhiambo Washington wrote:
> > I am getting this error after I did a git pull and build.
> >
> > (venv) [mailman3@gw ~/git]$ /opt/mailman/mm/bin/mailman-post-update
> > + '[' False == False ']'
> > + mkdir -p /opt/mailman/mm/static
> > + /opt/mailman/mm/bin/django-admin collectstatic --clear --noinput
> > --verbosity 0
> > +* /opt/mailman/mm/bin/django-admin compress*
> > CommandError: An error occurred during rendering
> >
> /opt/mailman/mm/venv/lib/python3.7/site-packages/HyperKitty-1.3.4rc2-py3.7.egg/hyperkitty/templates/hyperkitty/404.html:
> > /usr/local/lib/ruby/site_ruby/2.7/rubygems/dependency.rb:311:in
> `to_specs':
> > Could not find 'sass-listen' (~> 4.0.0) among 4 total gem(s)
> ...
>
>
> Ruby-sass is no longer supported. Please see the Sass compiler section
> at
> <https://docs.mailman3.org/en/latest/install/virtualenv.html#dependencies
> >.
>
I uninstalled rubygem-sass from the OS. I don't remember consciously
installing that because it was never in the guide I followed (which is your
own writeup).
But I still have a problem:
(venv) [mailman3@gw ~/mm]$ /opt/mailman/mm/bin/mailman-post-update
+ '[' False == False ']'
+ mkdir -p /opt/mailman/mm/static
+ /opt/mailman/mm/bin/django-admin collectstatic --clear --noinput
--verbosity 0
+ /opt/mailman/mm/bin/django-admin compress
CommandError: An error occurred during rendering
/opt/mailman/mm/venv/lib/python3.7/site-packages/django_mailman3-1.3.5-py3.7.egg/django_mailman3/templates/socialaccount/signup.html:
*/bin/sh: sass: not found*
pip3 install sass fails:
.....
ERROR: Command errored out with exit status 1:
/opt/mailman/mm/venv/bin/python -u -c 'import sys, setuptools, tokenize;
sys.argv[0] =
'"'"'/tmp/pip-install-vnlujru1/sass_15812b8baa1b405c8130edb21a4f4316/setup.py'"'"';
__file__='"'"'/tmp/pip-install-vnlujru1/sass_15812b8baa1b405c8130edb21a4f4316/setup.py'"'"';f=getattr(tokenize,
'"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"',
'"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))'
install --record /tmp/pip-record-_f8rgww1/install-record.txt
--single-version-externally-managed --compile --install-headers
/opt/mailman/mm/venv/include/site/python3.7/sass Check the logs for full
command output.
The complete failure text is at https://pastebin.ubuntu.com/p/tsB2CCNrQG/
Maybe it's time to blow up everything in the virtualenv and start over
because I am not sure what caused this.
--
Best regards,
Odhiambo WASHINGTON,
Nairobi,KE
+254 7 3200 0004/+254 7 2274 3223
"Oh, the cruft.", grep ^[^#] :-)
4 years, 5 months

[MM3-users] upgraded Django & flufl.lock now do not receive own postings
by Christian
I just upgraded Django from version 3.0.11 to 3.2.15 receiving this
confirmation
> Successfully installed Django-3.2.15 asgiref-3.5.2
I also upgraded flufl.lock from version 7.0 to 7.1
> Successfully installed flufl.lock-7.1
Then I restarted mailman, qcluster & gunicorn
Now for some reason I'm not receiving my own postings to the list whereas
before I was. 'Receive own postings' is still set to yes.
Thank you!
-----Original Message-----
From: David Newman <dnewman(a)networktest.com>
Sent: Friday, July 8, 2022 11:29 AM
To: mailman-users(a)mailman3.org
Subject: [MM3-users] Re: FYI: Django security releases issued: 4.0.6 and
3.2.14
On 7/8/22 6:34 AM, Stephen J. Turnbull wrote:
> David Newman writes:
>
> > Interesting -- that does produce two directories with names starting
> > with a tilde:
> >
> > /opt/mailman/venv/lib/python3.9/site-packages/~jango:
> > /opt/mailman/venv/lib/python3.9/site-packages/~jango-3.0.14.dist-info:
>
> I would guess that those are the previous versions before the upgrade,
> moved out of the way in case a revert-to-previous was needed. Again,
> guessing, they should have been removed by the upgrade process once
> the new package was fully installed. Was there an interrupted or
> partially successful upgrade in the past?
Yes
>
> So I would guess you can remove them. Probably you have the relevant
> Ubuntu packages cached somewhere, and they're probably available from
> Ubuntu if you really wanted them.
This system runs Debian 11, with everything installed in a venv. I'm unclear
on the relationship between the usual apt* tools and pip, and just do
everything Mailman-related using pip.
On 7/8/22 7:47 AM, Mark Sapiro wrote:
> When pip is doing an upgrade of the xyz package, it renames the existing
> package as ~yz and then ultimately deletes the old ~yz package after >
successfully installing the new xyz. In this case, the upgrade was >
aborted because of the Django<3.1 constraint in mailman-web and >
apparently pip then installed Django<3.1 and left the ~jango* > directories
behind.
Ahhh, that explains it.
Thanks for your replies. I've deleted the ~ directories and so far have not
noticed any adverse effects.
dn
_______________________________________________
Mailman-users mailing list -- mailman-users(a)mailman3.org To unsubscribe send
an email to mailman-users-leave(a)mailman3.org
https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/
2 years, 10 months

[MM3-users] Re: Message shows up individually but not in the thread
by Marvin Gülker
Am 03. November 2017 um 12:35 Uhr -0700 schrieb Mark Sapiro <mark(a)msapiro.net>:
> Are you running all of Django's periodic tasks?
They are running. This is the excerpt from /etc/crontab:
# Mailman jobs
@daily mailman bash -c 'cd /home/mailman && . /home/mailman/env3/bin/activate && mailman digests --send'
@hourly mailman bash -c 'cd /home/mailman && . /home/mailman/env2/bin/activate && django-admin runjobs hourly --pythonpath /home/mailman/mailman-suite/mailman-suite_project --settings settings'
@daily mailman bash -c 'cd /home/mailman && . /home/mailman/env2/bin/activate && django-admin runjobs daily --pythonpath /home/mailman/mailman-suite/mailman-suite_project --settings settings'
@weekly mailman bash -c 'cd /home/mailman && . /home/mailman/env2/bin/activate && django-admin runjobs weekly --pythonpath /home/mailman/mailman-suite/mailman-suite_project --settings settings'
@monthly mailman bash -c 'cd /home/mailman && . /home/mailman/env2/bin/activate && django-admin runjobs monthly --pythonpath /home/mailman/mailman-suite/mailman-suite_project --settings settings'
@yearly mailman bash -c 'cd /home/mailman && . /home/mailman/env2/bin/activate && django-admin runjobs yearly --pythonpath /home/mailman/mailman-suite/mailman-suite_project --settings settings'
* * * * * mailman bash -c 'cd /home/mailman && . /home/mailman/env2/bin/activate && django-admin runjobs minutely --pythonpath /home/mailman/mailman-suite/mailman-suite_project --settings settings'
2,17,32,47 * * * * mailman bash -c 'cd /home/mailman && . /home/mailman/env2/bin/activate && django-admin runjobs quarter_hourly --pythonpath /home/mailman/mailman-suite/mailman-suite_project --settings settings
Obviously, mailman-suite is installed at /home/mailman/mailman-suite and
owned by user 'mailman', with the actual Django project in the
subdirectory 'mailman-suite_project', just as cloned from the Git
repository. The only difference from the official guide here is that I
took the liberty to place Mailman into two virtualenvs (a Python2 one
for the Django project, and a Python3 one for Mailman-Core*).
There are no errors reported with this in /var/log/cron.log. And before
you ask, the task queue is running as well. The uWSGI config has this:
# Setup the django_q related worker processes.
attach-daemon = ./manage.py qcluster
And the qcluster process shows both up in the process list and is
happily logging away in the uWSGI log.
Greetings
Marvin
* It'd be great if the mailman-suite was moved to Python 3 at some
point. That way one wouldn't need two separate virtualenvs.
--
Blog: https://www.guelkerdev.de
PGP/GPG ID: F1D8799FBCC8BC4F
7 years, 7 months

[MM3-users] Re: I did something stupid. Can i back out of it?
by William Oliver
On Sat, 2022-02-19 at 12:03 -0800, Mark Sapiro wrote:
> On 2/19/22 08:33, William Oliver wrote:
> >
> > So... I run a small mailinglist using mailman3 that has been
> > workiing
> > great for a couple of months. Last week, all my users from gmail
> > got
> > kicked off because gmail decided that the list messages were
> > "unsolicited email". I didn't find out about it until the users
> > hit
> > their mailman3 bounce limit. I *thought* would be seeing all the
> > bounce messages, but apparently not. I didn't see any config
> > settings
> > for "see all the bounce messages" so i thought to myself, "Self,
> > well
> > maybe that's because my mailinglist username doesn't have a
> > mailbox in
> > /home/listname".
>
>
> Assuming your Mailman core version is 3.3.5 and Postorius is 1.3.6,
> you
> will see settings like `Notify owner on bounce increment`, ` Notify
> owner on disable` and `Notify owner on removal` under `Bounce
> Processing`. Presumable you did get the notification of removal, so
> delivery to the owner works. Are the increment and disable (or maybe
> just disable if your versions are older) notices set to Yes?
Found it. Thanks.
>
>
> > So, I decided to try that. I created /home/listname/Maildir/* and
> > logged in as fplist to see if it would put mail there. In order to
> > log
> > in as listname, I gave the user listname a password.
>
>
> Can't you just reverse those steps. I.e. remove /home/listname/ and
> remove the listname user?
>
Well, that was my inclination, but I didn't know if I needed to have a
user by the name of listname. I was afraid that if I just deleted the
user "listname" it would cause even more problems.
I had created that user back when I was using another mailinglist
package -- a Joomla plugin (that doesn't work nearly as well as
mailman3). I was afraid to just type in "userdel -r" in case mailman3
needed a "real" user...
So, I can just kill the listname user altogether?
billo
3 years, 4 months

[MM3-users] Re: mailman-cli tools
by Abhilash Raj
On Wed, Sep 27, 2017, at 10:29 AM, Dmitry Makovey wrote:
> On 09/27/2017 10:20 AM, Abhilash Raj wrote:
> > On Wed, Sep 27, 2017, at 08:44 AM, Mark Sapiro wrote:
> >> On 09/27/2017 08:26 AM, Dmitry Makovey wrote:
> >>> On 09/27/2017 08:25 AM, Dmitry Makovey wrote:
> >>>> I've come across mailman-cli docs:
> >>>>
> >>>> http://mailman-cli.readthedocs.io/en/latest/src/mailmanclient/cli/docs/usin…
> >>>>
> >
> > This is basically one of our GSoC projects which hasn't yet been merged
> > with MailmanClient. It uses the REST API to to provide a command line
> > client for Mailman, while there hasn't been any in-compatible changes in
> > API since this project was finished, I am not sure about the current
> > status of it.
> >
> >>>> yet I cannot figure out what's the official source for the installation.
> >
> > Official source for MailmanClient is at gitlab.com/mailman/mailmanclient
> > and it doesn't have a CLI, the Github project you linked to says right
> > on the top that it is not official project (Thanks for that Rajeev!).
>
> I did see that, thus I was asking the question here.
>
> > Also, I would say not to use this client to remotely access Mailman, the
> > REST API is not meant to be exposed over internet (unless you have a VPN
> > or other sort of setup to securely access the box remotely).
> >
>
> in my case - I need to use REST API since we're deploying with docker
> and pieces that need to integrate with mailman commands now live in a
> different container (and very likely on a different machine). I do need
> to be able to execute commands remotely - I can handle securing of that
> connection, but it is not an option for me to run "fat" docker
> containers thus the only interconnect is via sockets (either UNIX or
> TCP).
The CLI project is basically a Shell+CLI based on MailmanClient (python
library for Mailman API) and Mailman Core's REST API. So, if I
understand correctly, this would run commands over REST API like you
want.
--
Abhilash Raj
maxking(a)asynchronous.in
7 years, 9 months

[MM3-users] Re: mailman-core installation on debian stretch/maria-db
by Wolfgang Bock
Am 10.03.2018 um 23:44 schrieb Mark Sapiro:
> How? Did you install
> <https://packages.debian.org/stretch-backports/mailman3-core>?
-> No, if I had known this, I wouldn't waste my time for the last 3 days
in fiddeling and googleling ...
> If so, these are probably issues with the Debian package.
>
> You may find<https://gitlab.com/mailman/mailman/issues/455> to be of
> interest.
>
> If you installed Mailman some other way, How?
-> From here:
http://docs.mailman3.org/en/latest/prodsetup.html#installing-mailman-core
including dependencies
>
>> 1. On "mailman start" I got the error message:
>> Starting Mailman's master runner
>> /usr/bin/python3: can't open file '/sbin/master': [Errno 2] No such file
>> or directory
> Where is it? What does 'which master' show?
-> /usr/local/bin/master
-> After I set a symlink to /sbin/master another errormessage occurs
>> 2. connection to maria-db
>> In debian stretch maria-db is running. In my mailman.cfg I set:
>> [database]
>> class: mailman.database.mysql.MySQLDatabase
>> url:
>> mysql+pmysql://#username#:#user-pawo#@localhost/#databasename#?charset=utf8&use_unicode=1
> should that be mysql+pymysql ?
-> Yes, according to:
http://mailman.readthedocs.io/en/latest/src/mailman/docs/database.html
-> Not right??
After that I decided to delete mailman via pip and took a new approach
via debians apt-get ... mailman 3
So far so good, now new errormessage:
Traceback (most recent call last):
File "/usr/local/bin/mailman", line 11, in <module>
sys.exit(main())
File "/usr/local/lib/python3.5/dist-packages/mailman/bin/mailman.py",
line 94, in main
initialize(config_path)
File
"/usr/local/lib/python3.5/dist-packages/mailman/core/initialize.py",
line 189, in initialize
initialize_2(propagate_logs=propagate_logs)
File
"/usr/local/lib/python3.5/dist-packages/mailman/core/initialize.py",
line 160, in initialize_2
config.db = getUtility(IDatabaseFactory, utility_name).create()
File
"/usr/local/lib/python3.5/dist-packages/mailman/database/factory.py",
line 52, in create
database = call_name(database_class)
File
"/usr/local/lib/python3.5/dist-packages/mailman/utilities/modules.py",
line 67, in call_name
named_callable = find_name(dotted_name)
File
"/usr/local/lib/python3.5/dist-packages/mailman/utilities/modules.py",
line 51, in find_name
return getattr(sys.modules[package_path], object_name)
AttributeError: module 'mailman.database.mysql' has no attribute
'MYSQLDatabase'
Another question is, where can I find the sql-command within the
database mailman3 like CREATE TABLE x and TABLE y as I created a
database mailman3 which is empty??
Thanks for your help in advance.
Regards Wolfgang
7 years, 3 months

[MM3-users] Re: spanish localization
by Guillermo Hernandez (Oldno7)
On 11/2/21 20:15, Mark Sapiro wrote:
> On 2/11/21 3:47 AM, Guillermo Hernandez (Oldno7) via Mailman-users wrote:
>> I contributed in january to translate to spanish all the items left in
>> Mailman Core, Django-mailman, HyperKitty and Postorius via Weblate. I
>> thought they will be used in the next upgrade, but I cannot see any
>> improvement and there are many words untranslated.
>
> The Spanish translations for Mailman core and HyperKitty are currently
> completely up to date with weblate. django-mailman3 differs in one
> string that was translated on Feb 10 and hasn't yet been merged.
> Postorius also differs in a few places from the Feb 10 version that
> hasn't yet been merged.
Ok. Thanks for checking it. I put my little contribution in Weblate and
I like that it could be used by anyone.
> Other than that, the translations should be good.
>
>
>> Is there any way to upgrade the .po files in order to get the last
>> translation?
>
> For the web UI you need to run the django management `compilemessages`
> command.
I tried to run this using the same command as I did for the
"collectstatic" (that solved all my previous problems for the upgrade)
and "migrate" runs but it shows me an error:
su -m mailman3 -c "python3 manage.py compilemessages"
CommandError: This script should be run from the Django Git checkout or
your project or app tree, or with the settings module specified.
if I try with --settings param (for I missunderstood the error message)
it shows the same:
su -m mailman3 -c "python3 manage.py compilemessages --settings settings"
CommandError: This script should be run from the Django Git checkout or
your project or app tree, or with the settings module specified.
I tried to find any doc regarding the use of the "compilemessages"
command but I couldn't
As far as I can see (I runned it with -h parm) this had to be related to
the main python module, but I cannot understand why the pip upgrade did
not do the job.
I'm lost.
Can you, please, point me in the right direction?
> For Mailman core you need to run
> ```
> cd mailman/messages/es/LC_MESSAGES
> msgfmt -o mailman.mo mailman.po
> ```
> to compile the mailman.po file for gettext.
>
4 years, 4 months

[MM3-users] Re: not correct language in subject(s)
by Jens Günther
Thanks Mark for the tests and your thoughts on this matter.
Am 23.05.23 um 17:19 schrieb Mark Sapiro:
>
> That file was for a test only. The German message catalog is at
> mailman/messages/de/LC_MESSAGES/. That directory should contain a
> mailman.po and a mailman.mo. If there is no mailman.mo, it needs to be
> created. The source distribution contains a generate_mo.sh script to
> generate these for all languages, but you can do the German one by
> changing to the mailman/messages/de/LC_MESSAGES/ directory in the
> running installation and doing
>
> msgfmt mailman.po -o mailman.mo
I just checked the mailman/messages/de/LC_MESSAGES directory and there
was only a mailman.po. I tried to create the mo-file with the command
you provided, unfortunately it doesn't work in the running
docker-container (obviously the gettext-package is missing ... and can't
install it with apt, but this is another docker-related problem, shall I
open another thread?).
I did create on OS-level the mo-file, restarted the container and now
the welcome- and goodbye-subject is indeed in German, coolio!
2 thoughts on this for me is:
- Shall I create all the mo-files (the other folders also only contain
the po)? If so, how would it be possible?
- How can I make it persistent? (probably it should be included in the
repo!? also another thread or an issue regarding maxxking's repo!?)
>
> I just tested, and the notice to the moderator of a held message is in
> the list's preferred language including the Subject: and the moderation
> reason, and the notice to the user sending a held message is in the
> User's preferred language for that list including the Subject: and the
> moderation reason.
>
> I suspect your issue is you don't have the compiled mailman.mo German
> message catalog. The text is in German because it comes from templates
> and you presumably do have German language templates.
>
Exactly. What I was wondering: for the welcome-messages I did not have
explicit templates for those lists/domains/site that I wrote in German,
it has to be from the predefined templates, which are stored elsewhere
the in the mo-files!? (actually I don't get this point exactly but
wouldn't bother, if the above works).
Thanks again!
2 years, 1 month

[MM3-users] Re: Removing a mail addresses and users
by Abhijith PA
Hi Mark,
On 11/06/20 1:16 am, Mark Sapiro wrote:
> On 6/10/20 10:23 AM, Abhijith PA via Mailman-users wrote:
>> Hello.
>>
>> I tried to remove random email address signing ups (which I signed up
>> while testing) via admin panel. After removing I tried to sign up again,
>> but I am getting,
>>
>> 'A user is already registered with this e-mail address'
>
> You removed the user's subscription from the list, but you didn't remove
> the user from the system.
>
> Mailman3 has a concept of `user` which didn't exist in Mailman 2.1.
> User's have addresses and a user or one of the user's addresses can
> belong to a list with one or more roles (non-member, member, moderator
> or owner)
In my case these user signups were just to test postorious. These mail
accounts didn't subscribed to anything.
>> Combing through the database, I found auth_user table in mailman3web db
>> still contain those mail address. How to wipe email address entirely
>> from the db so I can signup again without the 'forget password' method
>
> There are a couple of things. If you log in to the web UI as a django
> superuser, you can go to the django admin UI -> Users section and delete
> the User, but I think that will only delete the web user and not delete
> the user from Mailman core.
>
> You can also log in to the web UI as the user and go to
> <https://lists.mailman3.org/user-profile/delete>, but that again only
> deletes the web user, and if you could do that, you could just subscribe
> once you're logged in, so I assume that's what you want to avoid.
>
> I don't think there is a way for a user as opposed to a site admin to
> delete her user record from Mailman core and even for a site admin,
> there's no way in Postorius to delete a user from core. It has to be
> done via REST
> <https://docs.mailman3.org/projects/mailman/en/latest/src/mailman/rest/docs/…>
> or `mailman shell`.
>
Thanks for the link, let me try that out.
--abhijith
5 years

[MM3-users] Re: A little stuck with installation of MM3 - ModuleNotFoundError: No module named 'flufl.lock'
by Odhiambo Washington
On Thu, 30 Jul 2020 at 00:13, Mark Sapiro <mark(a)msapiro.net> wrote:
> On 7/29/20 12:15 AM, Odhiambo Washington wrote:
> >
> > Yes, the same problem.
> > I created the file __init__.py in /opt/mailman/mm
> > However, when I run using the wsgi.py I ended up (still do!) with the
> error:
> >
> > [Wed Jul 29 10:08:51.869144 2020] [wsgi:info] [pid 79132] [remote
> > 197.232.81.246:64709] mod_wsgi (pid=79132, process='mailman-web',
> > application='mm3-lists.server.name|/mm3'): Loading Python script file
> > '/opt/mailman/mm/wsgi.py'.
>
> What is the contend of the file /opt/mailman/mm/wsgi.py?
>
[wash@gw ~]$ cd /opt/mailman/mm/
[wash@gw /opt/mailman/mm]$ less wsgi.py
"""
WSGI config for HyperKitty project.
It exposes the WSGI callable as a module-level variable named
``application``.
For more information on this file, see
https://docs.djangoproject.com/en/{{ docs_version }}/howto/deployment/wsgi/
"""
import os
# import sys
# import site
# For some unknown reason, sometimes mod_wsgi fails to set the python paths
to
# the virtualenv, with the 'python-path' option. You can do it here too.
#
# # Remember original sys.path.
#prev_sys_path = list(sys.path)
# # Add here, for the settings module
#site.addsitedir(os.path.abspath(os.path.dirname(__file__)))
# # Add the virtualenv
#venv = os.path.join(os.path.abspath(os.path.dirname(__file__)),
# '..', 'lib', 'python2.6', 'site-packages')
# site.addsitedir(venv)
# # Reorder sys.path so new directories at the front.
# new_sys_path = []
# for item in list(sys.path):
# if item not in prev_sys_path:
# new_sys_path.append(item)
# sys.path.remove(item)
# sys.path[:0] = new_sys_path
from django.core.wsgi import get_wsgi_application
os.environ.setdefault("DJANGO_SETTINGS_MODULE", "settings")
application = get_wsgi_application()
> You previously posted the setting of WSGIDaemonProcess in your Apache
> config as:
>
> > WSGIDaemonProcess mailman-web display-name=mailman-web
> maximum-requests=1000 umask=0002 user=mailman3 \
> > group=mailman3
> python-path=/opt/mailman/mm/venv/lib/python3.7/site-packages:/opt/mailman/mm/venv/lib/python3.7
> \
> > python-home=/opt/mailman/mm/venv home=/opt/mailman/mm/var
>
> Is it still that?
>
This is from wsgi.conf in my Apache Includes/.
It's a copy/paste of your version, with the only modification being the
change pf python version to 3.7
--
Best regards,
Odhiambo WASHINGTON,
Nairobi,KE
+254 7 3200 0004/+254 7 2274 3223
"Oh, the cruft.", grep ^[^#] :-)
4 years, 11 months

[MM3-users] Re: integrating mm3 with postfix / lmtp
by Fabian A. Santiago
On October 25, 2017 9:13:20 PM EDT, Mark Sapiro <mark(a)msapiro.net> wrote:
>On 10/25/2017 05:41 PM, Fabian A. Santiago wrote:
>>
>> No to the domains part and I think virtual alias maps is needed:
>>
>> mail postfix/trivial-rewrite[19445]: warning: do not list domain xxx
>in BOTH virtual_mailbox_domains and relay_domains
>> Oct 25 20:39:19 mail postfix/trivial-rewrite[19445]: warning: do not
>list domain xxx in BOTH virtual_mailbox_domains and relay_domains
>> Oct 25 20:39:19 mail postfix/submission/smtpd[19441]: NOQUEUE:
>reject: RCPT from
>pool-108-53-239-102.nwrknj.fios.verizon.net[108.53.239.102]: 550 5.1.1
><test123@xxx>: Recipient address rejected: User unknown in virtual
>mailbox table; from=<fsantiago@xxx> to=<test123@xxx> proto=ESMTP
>helo=<[10.0.0.29]>
>
>(above slightly sanitized for return to the list)
>
>The issue here is your list domain cannot be a virtual_mailbox_domain
>or
>a virtual_alias_domain.
>
>I have the same issue on mail.python.org where we have both Mailman 2
>and Mailman 3 lists @python.org. and python.org is a
>virtual_alias_domain.
>
>I have a group of MRs for a branch that implements "alias_domains" to
>deal with this.
>
>Basically it works by creating another (virtual_alias_maps)
>postfix_vmap
>mapping to map list addresses @python.org to addresses @x.python.org.
>Then the postfix_domains and postfix_lmtp maps have the x.python.org
>domain and there is a patch to mailman/runners/lmtp.py to map the
>x.python.org domain back to python.org.
>
>The various MRs are
><https://gitlab.com/mailman/mailman/merge_requests/202> for the core,
><https://gitlab.com/mailman/mailmanclient/merge_requests/18> for the
>REST bindings used by Postorius and
><https://gitlab.com/mailman/postorius/merge_requests/186> to be able to
>set an alias_domain via Postorius.
>
>That's not all implemented at mail.python.org. What's there is the
>basic
>Postfix config, a bash script the generate the new mappings from the
>old
>and a simple patch to mailman/runners/lmtp.py.
>
>So, the bottom line is it can be done and it's in process, but it won't
>really be supported until Mailman 3.2. In the mean time, you just need
>to have a separate domain for your lists that isn't a virtual_*_domain.
Ok thanks. At least I have a clear answer now. Any ETA on 3.2 in mind yet?
--
Thanks,
Fabian S.
OpenPGP: 3C3FA072ACCB7AC5DB0F723455502B0EEB9070FC
7 years, 8 months

[MM3-users] Re: Sending a message to a subscription applicant when a subscription request is made
by Allan Hansen
Much appreciated, Mark.
We'll go with (a.), as it's a one-liner as I expected, and it does not require me to change the policy. I'll just need to make some adjustments to the template contents.
Yours,
Allan
On 3/28/23, 11:29, "Mark Sapiro" <mark(a)msapiro.net <mailto:mark@msapiro.net>> wrote:
On 3/28/23 10:45, Allan Hansen wrote:
>
> a. That we change the lines in the Python program in our installation that send 'list:admin:action:subscribe' to the list admins to instead send the template to the applying subscriber.
This patch will do that
--- a/src/mailman/app/subscriptions.py
+++ b/src/mailman/app/subscriptions.py
@@ -338,7 +338,7 @@ class SubscriptionWorkflow(_SubscriptionWorkflowCommon):
# This message should appear to come from the <list>-owner
so as
# to avoid any useless bounce processing.
msg = UserNotification(
- self.mlist.owner_address, self.mlist.owner_address,
+ self.address.email, self.mlist.owner_address,
subject, text, self.mlist.preferred_language)
msg.send(self.mlist)
# The workflow must stop running here.
Watch for wrapped lines. Note that this only works if Admin immed notify
is Yes.
> b. That we change the lines in the Python program in our installation that send 'list:user:action:subscribe' to the subscriber with an unverified address to always do this, even when the incoming address has already been verified.
I think this patch will do it, but needs testing
--- a/src/mailman/app/subscriptions.py
+++ b/src/mailman/app/subscriptions.py
@@ -285,7 +285,7 @@ class SubscriptionWorkflow(_SubscriptionWorkflowCommon):
# If we do not need the user's confirmation, then skip to the
# moderation checks.
if self.mlist.subscription_policy is SubscriptionPolicy.moderate:
- self.push('moderation_checks')
+ self.push('send_confirmation')
return
# If the subscription has been pre-confirmed, then we can skip the
# confirmation check can be skipped. If moderator approval is
Again watch for wrapped lines.
--
Mark Sapiro <mark(a)msapiro.net <mailto:mark@msapiro.net>> The highway is for gamblers,
San Francisco Bay Area, California better use your sense - B. Dylan
_______________________________________________
Mailman-users mailing list -- mailman-users(a)mailman3.org <mailto:mailman-users@mailman3.org>
To unsubscribe send an email to mailman-users-leave(a)mailman3.org <mailto:mailman-users-leave@mailman3.org>
https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/ <https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/>
Archived at: https://lists.mailman3.org/archives/list/mailman-users@mailman3.org <mailto:mailman-users@mailman3.org>/message/NNMWW4PW55H4OLA3NTAKZLRNIEV2HHUA/
This message sent to hansen(a)rc.org <mailto:hansen@rc.org>
2 years, 3 months

[MM3-users] Re: Permission denied for fulltext_index
by Jan Eden
On 2022-11-30 10:22, Mark Sapiro wrote:
> On 11/30/22 08:41, Jan Eden via Mailman-users wrote:
> >
> > Changing the PATH value to a full path (/opt/mailman/fulltext_index)
> > and restarting mailman-web generates a different error:
>
>
> Yes, it should be a full path.
I encountered yet another problem with emails not getting archived
anymore:
> ERROR 2022-12-01 09:18:00,111 1337915 hyperkitty.views.mailman Access to the archiving API endpoint was forbidden from IP XXX.XXX.XXX.XXX, your MAILMAN_ARCHIVER_FROM setting may be misconfigured
where XXX.XXX.XXX.XXX is my server's public IP. This was probably caused
by the switch to uwsgi_pass/a file socket, and could be fixed by adding
MAILMAN_ARCHIVER_FROM = ('XXX.XXX.XXX.XXX', '::1')
to /etc/mailman3/settings.py.
> > > ERROR 2022-11-30 16:38:37,953 1028315 django.request Internal Server Error: /archives/list/testing@lists.eden.one/thread/T6MCILAVQYV5QIOGHJB3JNJ26Z7E2Z35/reattach-suggest
> > > Traceback (most recent call last):
> > > File "/opt/mailman/venv/lib/python3.10/site-packages/django/core/handlers/exception.py", line 55, in inner
> > > response = get_response(request)
> > > File "/opt/mailman/venv/lib/python3.10/site-packages/django/core/handlers/base.py", line 197, in _get_response
> > > response = wrapped_callback(request, *callback_args, **callback_kwargs)
> > > File "/opt/mailman/venv/lib/python3.10/site-packages/hyperkitty/lib/view_helpers.py", line 137, in inner
> > > return func(request, *args, **kwargs)
> > > File "/opt/mailman/venv/lib/python3.10/site-packages/hyperkitty/views/thread.py", line 454, in reattach_suggest
> > > sugg_thread = msg.object.thread
> > > AttributeError: 'NoneType' object has no attribute 'thread'
>
>
> This says that searching the archive for this list for messages matching the
> current message subject returns None. It is probably a bug that we don't
> test for this, but what exactly are you doing?
> See the post at https://lists.mailman3.org/archives/list/mailman-users@mailman3.org/message…
> for the only way I've been able to create an error like this.
There are currently 5 (test) threads in the archive. After changing the
PATH in the HAYSTACK_CONNECTIONS dict to /opt/mailman/fulltext_index,
and fixing the issue with MAILMAN_ARCHIVER_FROM above,
/opt/mailman/web/logs/mailmanweb.log does not display new error
messages, but I do not get any suggestions for reattaching threads, and
a search for a specific thread subject ("Third test") does not return
any results.
So reattachment works in principle, but the suggest/search function does
not.
- Jan
2 years, 7 months

[MM3-users] Re: Errors while importing mm2 list archives - SOLVED
by Odhiambo Washington
On Tue, Dec 20, 2022 at 8:32 PM Mark Sapiro <mark(a)msapiro.net> wrote:
> On 12/20/22 06:48, Odhiambo Washington wrote:
> >
> > There is a WARNING on
> >
> https://docs.list.org/en/latest/install/virtualenv.html#virtualenv-install
> > which says one must create the config file as /etc/mailman3/mailman.cfg
> > How to force mailman to read that file is something I haven't understood,
> > but turns out to be what has taken me days trying to get things right.
>
>
> If you run the `mailman` command without any -C option, it will look for
> a config in /etc/mailman3/mailman.cfg
>
In my case, running `mailman` without any arguments just makes it grok :)
(venv) [mailman@gw ~/mm]$ mailman info
GNU Mailman 3.3.7 (Tom Sawyer)
Python 3.9.15 (main, Dec 6 2022, 09:25:59)
[Clang 13.0.0 (git@github.com:llvm/llvm-project.git
llvmorg-13.0.0-0-gd7b669b3a
*config file: /opt/mailman/mm/mailman.cfg*
db url: mysql+pymysql://mailman_user:XXXXXXXX@localhost
/mailman3db?charset=utf8mb4&use_unicode=1
devmode: DISABLED
REST root url: https://localhost:8001/3.1/
REST credentials: restadmin:restpass
(venv) [mailman@gw ~/mm]$ mailman
Usage: mailman [OPTIONS] COMMAND [ARGS]...
The GNU Mailman mailing list management system Copyright 1998-2018 by the
Free Software Foundation, Inc. http://www.list.org
Options:
--version Show the version and exit.
--run-as-root Running mailman commands as root is not recommended and
mailman will refuse to run as root unless this option
is
specified.
-C, --config FILE Configuration file to use. If not given, the
environment
variable MAILMAN_CONFIG_FILE is consulted and used if
set. If neither are given, a default configuration
file
is loaded.
-h, --help Show this message and exit.
....
> Ultimately, when I did the import, there was only one email from the
> > archives that failed to be imported - which I honestly don't mind, but
> > maybe there is a solution for this
> > "'utf-8' codec can't encode character '\udcae' in position 331:
> surrogates
> > not allowed" ??
>
>
> If you provide a copy of that message from the mbox, either on the list
> or to me directly, I'll investigate.
>
A mbox file containing that email and the associated thread can be
downloaded from here:
https://webmail.kictanet.or.ke/~wash/chunk_7.txt.gz
--
Best regards,
Odhiambo WASHINGTON,
Nairobi,KE
+254 7 3200 0004/+254 7 2274 3223
"Oh, the cruft.", egrep -v '^$|^.*#' ¯\_(ツ)_/¯ :-)
2 years, 6 months

[MM3-users] Re: Turn off social logins?
by Abhilash Raj
This is kind of a top-post, because I am not sure which message should my reply quote. Please excuse that part.
My thinking on this topic resonates with what Steve said, I don't think we should be forcing the Mailman Administrators to handle username passwords. Dare I say that most social auth providers have more incentive and money to keep their database secure than Mailman Administrators.
Having said that, it doesn't have to be either or between "social logins enabled by default" and "I don't want to see a Facebook button". I have actually thought about this before, but never have been able to get to it. I opened an issue too but can't find it right now.
Anyway, so the idea is that most social providers need some soft of configuration from the Admin. Today, we enable them by default, but they don't work by default. I think we could make both sides happy if we were to just not show the social providers that aren't configured. What do others think?
Only two providers that I know of in Mailman's default list, which don't need any configuration, are Fedora and OpenID. I am happy to remove OpenID from default since I have never been able to actually get that to work. I am okay with removing Fedora too, which is a special case in Mailman 3 because of fedoralists.org being the first customer for Mailman 3 and Hyperkitty.
I don't have cycles to do that myself right now, so I would encourage people to step up to tackle this. I would obviously help them out with any Python, Mailman or Django related questions they might have.
Now, about the ease of being able to disable social logins, I think it should be possible to disable social logins with just a boolean flag in settings. Why haven't we done it yet? We didn't need to. What we provided was a **sample configuration**, with a huge emphasis on sample. We weren't maintaining it as an official set of configurations, but just something that one could use as a starting point. But that obviously didn't happen since people just downloaded and used it, some of which is ofc my own fault since the official docs doesn't say that what precisely you should be worried about changing from the sample.
The beauty (and ugliness) of Django's settings.py is that it is Python. We can disable social login if your CPU heats up[1], or if the stock price of the company goes below (or above? :P) a threshold, or heck, if the network firewall detects a packet heading out to their servers.
How Django's configuration works has been left kind-of open by the Django devs themselves, making every downstream project handle their own use case separately. We chose to just go with what was provided out of box, but that doesn't mean we can't do any better. We can do ini-style configs, it gets a tad bit complicated when there are unknown Python data structures that can't easily be represented in ini-style. We could do YAML, which supports more complicated data structures (nested maps and lists). OR, we could do JSON, but I find that less human readable.
Next topic, people worrying about customizing settings in settings_local.py and worrying about not getting newer updates. Isn't this how rest of the packaging and configuration world works? If you customize the `/etc/postfix/main.cf` you don't get the updates to default config (apt asks you, but you will choose not to update with your custom settings, right?) when you upgrade your postfix package from Debian and you need to pull in any new settings that package supports manually.
I have been (silently) working[2] on making the `mailman_suite` project a Python package (mailman3-web), like the Debian Maintainers did. That would be the right place to put whatever configuration logic we want to expose to our users. We can move to a model where you'd import all the settings from `mailman3_web.settings.base` and then customize all the fields that you do care about. But there will be downsides to it, like us updating a setting that changes the behavior of an already working site, and we can sure document those changes in release notes in big bold letters, but I still worry there will be people running `pip install -U` without thinking what does that even mean.
I don't know what should we do? What do other people managing configurations do? Maybe Debian Maintainers can chime in here?
[1]: https://xkcd.com/1172/
[2]: https://gitlab.com/maxking/mailman-suite/commits/master
On Fri, Feb 15, 2019, at 8:43 AM, Mark Sapiro wrote:
> On 2/14/19 11:10 PM, Stephen J. Turnbull wrote:
> > Torge Riedel writes:
> >
> > > - there is a way to do this now via settings_local.py, but feels
> > > a little bit risky if default configuration changes on update of
> > > mailman
> >
> > This should not be true. If it is, we need to fix that. Will check.
>
>
> It is more or less true. The issue is that unlike mm_cfg.py and
> Defaults.py in Mailman 2.1, the recommended way to set up Django in
> Mailman 3 is to point Django at settings.py for the default config, and
> the last thing in settings.py is
>
> try:
> from settings_local import *
> except ImportError:
> pass
>
> Thus,the only way settings_local.py can change something like
> INSTALLED_APPS is to redefine INSTALLED_APPS in it's entirety which
> leads to the possibility of INSTALLED_APPS changing in settings.py and
> those changes not being picked up in settings_local.py.
>
> The way around this is to remove the import of settings_local from
> settings.py and then put
>
> from settings import *
>
> at the beginning of settings_local.py and then point Django at
> settings_local rather than settings.
>
> Then you can do things like
>
> try:
> INSTALLED_APPS.remove('allauth.socialaccount.providers.google')
> except ValueError:
> pass
>
> in settings_local.py except there are still issues because, e.g.,
> INSTALLED_APPS is defined as a tuple (immutable) and not a list in
> settings.py.
>
> --
> Mark Sapiro <mark(a)msapiro.net> The highway is for gamblers,
> San Francisco Bay Area, California better use your sense - B. Dylan
> _______________________________________________
> Mailman-users mailing list -- mailman-users(a)mailman3.org
> To unsubscribe send an email to mailman-users-leave(a)mailman3.org
> https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/
>
--
thanks,
Abhilash Raj (maxking)
6 years, 4 months

[MM3-users] Re: Default values for lists in Mailman 3
by Markus Grandpré
Thank you very much for your answer.
Best regards,
Markus
Am 19.09.24 um 22:03 schrieb Mark Sapiro:
> On 9/19/24 05:46, Markus Grandpré wrote:
>> Dear list,
>>
>> I would like to activate the invitation setting for all lists as
>> default. In Mailman 2.1 I have done this in the file </etc/mailman/
>> mm_cfg.py>:
>>
>>
>> DEFAULT_SUBSCRIBE_OR_INVITE = Yes
>>
>>
>> How can I do this in Mailman 3?
>
> There is a draft merge request at https://gitlab.com/mailman/
> postorius/-/merge_requests/930 which implements a framework for setting
> Postorius defaults and creates a setting to set the default for pre-
> verified on the mass subscription page. Once merged, this can easily be
> extended to provide a default for Invitation.
>
> In the mean time, you can only do this by patching src/postorius/forms/
> list_forms.py like
> ```
> --- a/src/postorius/forms/list_forms.py
> +++ b/src/postorius/forms/list_forms.py
> @@ -1283,7 +1283,7 @@ class ListMassSubscription(forms.Form):
>
> invitation = forms.BooleanField(
> label=_('Invitation'),
> - initial=False,
> + initial=True,
> required=False,
> help_text=_(
> 'If checked, the other checkboxes are ignored and the
> users will '
> ```
>> Can I also transfer other default values like:
>>
>> ...
>> DEFAULT_SERVER_LANGUAGE = 'en'
>> DEFAULT_SEND_REMINDERS = 1
>> DEFAULT_SUBSCRIBE_OR_INVITE = Yes
>> DEFAULT_PRIVATE_ROSTER = 2
>> DEFAULT_ARCHIVE = Off
>> DEFAULT_ARCHIVE_PRIVATE = 1
>> ...
>>
>> from the very same configuration file to Mailman 3? Is there a
>> documentation of the default values for lists in Mailman 3?
>
> This is done by creating a list style with the desired defaults. See
> https://docs.mailman3.org/projects/mailman/en/latest/src/mailman/styles/
> docs/styles.html for documentation of styles and see https://gitlab.com/
> mailman/example-mailman-plugin for an example of creating a plugin in
> Mailman core to make a persistent style.
>
> There is no specific doc for the list settings. You need to look at
> https://gitlab.com/mailman/mailman/-/blob/master/src/mailman/styles/
> base.py for the various settings and https://gitlab.com/mailman/
> mailman/-/blob/master/src/mailman/styles/default.py to see which default
> classes are applied for various styles.
>
--
Markus Ludwig Grandpré
Universität Konstanz
Kommunikations-, Informations-, Medienzentrum (KIM)
Abteilung IT-Dienste Forschung und Lehre,
B803, Tel: ++49 7531 88 4342
9 months, 1 week

[MM3-users] Re: Issues with @gmail.com addresses
by Allan Hansen
Once this gets handled, Mohsen, Google has another issue with list servers:
If a subscriber who uses GMail posts a message to a list, then that subscriber will not get his/her own message from the server - Google eats it. All other subscribers will get it, but not the author. My subscribers run into this all the time and are up in arms over it. I tell them to complain to Google.
Yours,
Allan
On 9/5/23, 13:18, "Mark Sapiro" <mark(a)msapiro.net <mailto:mark@msapiro.net>> wrote:
On 9/5/23 12:59, Mohsen Masoudfar wrote:
> Hi,
>
> since 8/1/2023 I get complains from users with @gmail.com addresses, that they are not getting any emails.
> I checked the logs and I see that the emails are going out:
>
> to=<xxxx(a)gmail.com <mailto:xxxx@gmail.com>>, relay=email-smtp.us-east-1.amazonaws.com[35.169.171.20]:587, delay=0.46, delays=0.03/0.06/0.13/0.24, dsn=2.0.0, status=sent (250 Ok xxx )
>
> But it seems the users are getting email delivered to them.
> I’ve advised them to check their spam, promotions, and social folders and to add the list address to their email safe-senders lists, but still no success.
> Is there any way to help this list members?
Even though gmail publishes a DMARC policy of none, it has recently
started enforcing a stricter policy for mail From: the gmail.com domain.
You need to apply DMARC mitigations to mail From: the gmail.com domain.
There are two ways to do this.
One way is to set DMARC Mitigations -> DMARC Mitigate unconditionally to
Yes (and set DMARC mitigation action appropriately)
The other way requires upgrading Postorius and Mailman core to the heads
of the GitLab branches (core=3.3.9b1, postorius=1.3.9b1). Doing this
enables a DMARC Addresses setting which can be set to `^.*(a)gmail\.com$`
to apply DMARC mitigatations to mail From: the gmail.com domain
regardless of it's published policy.
--
Mark Sapiro <mark(a)msapiro.net <mailto:mark@msapiro.net>> The highway is for gamblers,
San Francisco Bay Area, California better use your sense - B. Dylan
_______________________________________________
Mailman-users mailing list -- mailman-users(a)mailman3.org <mailto:mailman-users@mailman3.org>
To unsubscribe send an email to mailman-users-leave(a)mailman3.org <mailto:mailman-users-leave@mailman3.org>
https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/ <https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/>
Archived at: https://lists.mailman3.org/archives/list/mailman-users@mailman3.org <mailto:mailman-users@mailman3.org>/message/WZY5IC3OVHVBHIGDT4TE3EWSSGMF6CYI/
This message sent to hansen(a)rc.org <mailto:hansen@rc.org>
1 year, 9 months

[MM3-users] Re: spanish localization
by Victoriano Giralt
On Fri, 2021-02-12 at 09:04 +0100, Guillermo Hernandez (Oldno7) via
Mailman-users wrote:
> On 11/2/21 20:15, Mark Sapiro wrote:
> > On 2/11/21 3:47 AM, Guillermo Hernandez (Oldno7) via Mailman-users
> > wrote:
> > > I contributed in january to translate to spanish all the items
> > > left in
> > > Mailman Core, Django-mailman, HyperKitty and Postorius via
> > > Weblate. I
> > > thought they will be used in the next upgrade, but I cannot see
> > > any
> > > improvement and there are many words untranslated.
> >
> > The Spanish translations for Mailman core and HyperKitty are
> > currently
> > completely up to date with weblate. django-mailman3 differs in one
> > string that was translated on Feb 10 and hasn't yet been merged.
> > Postorius also differs in a few places from the Feb 10 version that
> > hasn't yet been merged.
>
> Ok. Thanks for checking it. I put my little contribution in Weblate
> and I like that it could be used by anyone.
Actually, I was going to ask these same questions, because I dedicated
some hours to get the Spanish translation nearly finished, it was kind
of a "spiritual" need for me, being the person that seeded the efforts
for Mailman i18n support back in the late '90s :-) :-)
> I tried to run this using the same command as I did for the
> "collectstatic" (that solved all my previous problems for the
> upgrade)
> and "migrate" runs but it shows me an error:
>
> su -m mailman3 -c "python3 manage.py compilemessages"
> CommandError: This script should be run from the Django Git checkout
> or your project or app tree, or with the settings module specified.
I got this very same error, and was also confused, as manage.py runs at
the project level, not application level.
> I'm lost.
Do not feel bad, Guillermo, an old time pythonist with message
translations experience, that uses i18n for some of his applications,
is also dazzled and confused :-)
Confused-with-translations-ly, Victoriano.
--
Victoriano Giralt Innovation Director
Digital Transformation Vicerectorate University of Malaga
+34952131415 SPAIN
==================================================================
Note: signature.asc is the electronic signature of present message
A: Yes.
> Q: Are you sure ?
>> A: Because it reverses the logical flow of conversation.
>>> Q: Why is top posting annoying in email ?
4 years, 4 months

[MM3-users] Re: user mail not accepted
by Christian Stalberg
From smtp.log
Apr 26 00:17:39 2021 (807) ('127.0.0.1', 38370) Data: b'DATA'
Apr 26 00:17:39 2021 (807) ('127.0.0.1', 38370) Data: b'QUIT'
Apr 26 00:17:39 2021 (807) ('127.0.0.1', 38370) connection lost
Apr 26 00:17:39 2021 (807) Connection lost during _handle_client()
Apr 26 00:18:11 2021 (809)
<019301d73a31$8e8e54e0$abaafea0$(a)ncboliviapartners.org> smtp to
ncpoa(a)lists.ccalternatives.org for 83 recips, completed in 29.13376259803772
seconds
Apr 26 00:18:11 2021 (809)
<019301d73a31$8e8e54e0$abaafea0$(a)ncboliviapartners.org> post to
ncpoa(a)lists.ccalternatives.org from christian(a)ncboliviapartners.org, 5811
bytes
Apr 26 00:18:11 2021 (809)
<161939626169.810.9530678025639681522(a)zarathustra.ccalternatives.org> smtp
to ncpoa(a)lists.ccalternatives.org for 1 recips, completed in
0.0420069694519043 seconds
Apr 26 00:18:11 2021 (809)
<161939626169.810.9530678025639681522(a)zarathustra.ccalternatives.org> post
to ncpoa(a)lists.ccalternatives.org from
ncpoa-bounces(a)lists.ccalternatives.org, 869 bytes
Apr 26 11:52:22 2021 (819)
<161943793957.929.15640398646519288095(a)zarathustra.ccalternatives.org> smtp
to ssan(a)lists.ccalternatives.org for 1 recips, completed in
0.22335004806518555 seconds
Apr 26 11:52:22 2021 (819)
<161943793957.929.15640398646519288095(a)zarathustra.ccalternatives.org> post
to ssan(a)lists.ccalternatives.org from ssan-bounces(a)lists.ccalternatives.org,
765 bytes
Apr 26 11:52:22 2021 (819)
<161943793960.929.13309139087156940549(a)zarathustra.ccalternatives.org> smtp
to ssan(a)lists.ccalternatives.org for 2 recips, completed in
0.05862092971801758 seconds
Apr 26 11:52:22 2021 (819)
<161943793960.929.13309139087156940549(a)zarathustra.ccalternatives.org> post
to ssan(a)lists.ccalternatives.org from noreply(a)lists.ccalternatives.org, 810
bytes
Apr 26 11:55:22 2021 (819)
<161943812108.929.10391982256874011271(a)zarathustra.ccalternatives.org> smtp
to ssan(a)lists.ccalternatives.org for 1 recips, completed in
0.1459965705871582 seconds
Apr 26 11:55:22 2021 (819)
<161943812108.929.10391982256874011271(a)zarathustra.ccalternatives.org> post
to ssan(a)lists.ccalternatives.org from
ssan-confirm+2144530ad102026077911eac6eb574bcbd04be92(a)lists.ccalternatives.o
rg, 1526 bytes
Apr 26 12:01:30 2021 (817) Available AUTH mechanisms: LOGIN(builtin)
PLAIN(builtin)
Apr 26 12:01:30 2021 (817) Peer: ('127.0.0.1', 38556)
Apr 26 12:01:30 2021 (817) ('127.0.0.1', 38556) handling connection
Apr 26 12:01:30 2021 (817) ('127.0.0.1', 38556) Data: b'LHLO
zarathustra.ccalternatives.org'
Apr 26 12:01:30 2021 (817) ('127.0.0.1', 38556) Data: b'MAIL
FROM:<christian(a)sewagesludgeactionnetwork.com>'
Apr 26 12:01:30 2021 (817) ('127.0.0.1', 38556) sender:
christian(a)sewagesludgeactionnetwork.com
Apr 26 12:01:30 2021 (817) ('127.0.0.1', 38556) Data: b'RCPT
TO:<ssan-confirm+2144530ad102026077911eac6eb574bcbd04be92(a)lists.ccalternativ
es.org>'
Apr 26 12:01:30 2021 (817) ('127.0.0.1', 38556) recip:
ssan-confirm+2144530ad102026077911eac6eb574bcbd04be92(a)lists.ccalternatives.o
rg
Apr 26 12:01:30 2021 (817) ('127.0.0.1', 38556) Data: b'DATA'
Apr 26 12:01:30 2021 (817) ('127.0.0.1', 38556) Data: b'QUIT'
Apr 26 12:01:30 2021 (817) ('127.0.0.1', 38556) connection lost
Apr 26 12:01:30 2021 (817) Connection lost during _handle_client()
Apr 26 12:01:34 2021 (819)
<161943849287.814.5890052642238479423(a)zarathustra.ccalternatives.org> smtp
to ssan(a)lists.ccalternatives.org for 2 recips, completed in
0.06680631637573242 seconds
Apr 26 12:01:34 2021 (819)
<161943849287.814.5890052642238479423(a)zarathustra.ccalternatives.org> post
to ssan(a)lists.ccalternatives.org from noreply(a)lists.ccalternatives.org, 821
bytes
Apr 26 12:01:34 2021 (819)
<161943849292.814.6140111398379700592(a)zarathustra.ccalternatives.org> smtp
to ssan(a)lists.ccalternatives.org for 1 recips, completed in
0.04269862174987793 seconds
Apr 26 12:01:34 2021 (819)
<161943849292.814.6140111398379700592(a)zarathustra.ccalternatives.org> post
to ssan(a)lists.ccalternatives.org from ssan-request(a)lists.ccalternatives.org,
1335 bytes
Message sent that only the user receives:
Return-Path: <christian(a)sewagesludgeactionnetwork.com>
Delivered-To: ces(a)ecovillage.cc
Received: from box.ecovillage.cc ([127.0.0.1])
by box.ecovillage.cc with LMTP id MDucNBythmCTSwAAMoO61A
for <ces(a)ecovillage.cc>; Mon, 26 Apr 2021 05:07:56 -0700
X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on box.ecovillage.cc
X-Spam-Level:
X-Spam-Status: No, score=-1.1 required=5.0 tests=ALL_TRUSTED,DKIM_SIGNED,
DKIM_VALID,DKIM_VALID_AU,HTML_MESSAGE autolearn=ham
autolearn_force=no
version=3.4.2
X-Spam-Report:
* -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP
* 0.0 HTML_MESSAGE BODY: HTML included in message
* -0.1 DKIM_VALID Message has at least one valid DKIM or DK
signature
* 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not
necessarily
* valid
* -0.1 DKIM_VALID_AU Message has a valid DKIM or DK signature from
* author's domain
X-Spam-Score: -1.1
Received: from authenticated-user (box.ecovillage.cc [45.79.28.18])
(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256
bits))
(No client certificate requested)
by box.ecovillage.cc (Postfix) with ESMTPSA id 6EADF3E8CC
for <ssan(a)lists.naturalintelligence.us>; Mon, 26 Apr 2021 05:07:54
-0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple;
d=sewagesludgeactionnetwork.com; s=mail; t=1619438876;
bh=1M7F/uIS0bNG6cWjecy/a9QjskrHVwJHkjWRv+ffpM4=;
h=From:To:References:In-Reply-To:Subject:Date:From;
b=jXOswVZgFeHBB+sjIDqVkNBQqIbfZCj9ZUfpVwl10NQEkGaoxckPHNOKT6x9zIqsW
BZ7iZqqi2mWprVQ8LrK48Lp7gvCQ/ipqspMeLt3t+uljzTtryHmV6uJFEAU3hqM33Y
nQqX6Z8la8Ko40F9Ayb4h4e/MOfPdA4nadgf5hZzt/DzPFZvzUbG3V8lWcHuyJNA2y
SQkhbNubQ6iNEEB0SyBjoOjl3g3LVxjxY+9kMGGmX+1PFfW90CpDDShRmKkkscEWaA
NiV0fX6U5LENBBnc6Q9ImLgXuaLdCqlBRBumJBk+eUUr007rpXXVAPck2NvUzGyM2v
kNNGlT68hGzEg==
From: <christian(a)sewagesludgeactionnetwork.com>
To: <ssan(a)lists.naturalintelligence.us>
References:
In-Reply-To:
Subject: How US chemical industry lobbying and cash defeated regulation in
Trump era
Date: Mon, 26 Apr 2021 05:07:37 -0700
Message-ID: <020501d73a94$cbe17440$63a45cc0$(a)sewagesludgeactionnetwork.com>
MIME-Version: 1.0
Content-Type: multipart/alternative;
boundary="----=_NextPart_000_0206_01D73A5A.1F831170"
Thread-Index: Adc6h7I/qzBKx1yOT6aPOuipppacoQACatZAAADW1wA=
Content-Language: en-us
How US chemical industry lobbying and cash defeated regulation in Trump era
Industry's congressional allies defeated nearly all PFAS legislation while
the Trump EPA killed, watered down or slowalked new rules
https://www.theguardian.com/environment/2021/apr/26/us-chemical-companies-lo
bbying-donation-defeated-regulation
-----Original Message-----
From: Mark Sapiro <mark(a)msapiro.net>
Sent: Monday, April 26, 2021 2:05 PM
To: mailman-users(a)mailman3.org
Subject: [MM3-users] Re: user mail not accepted
On 4/26/21 5:16 AM, Christian Stalberg via Mailman-users wrote:
> I have a user whose moderation rule is 'Accept immediately' yet when
> they send a message for distribution to the list, they only receive it
> and it is not distributed via the list. Logfile entries below. Please
> advise. Btw I have another list on this same instance which is running
fine. Thank you.
>
> [26/Apr/2021:12:06:25 +0000] "GET
> /3.1/lists/ssan.lists.ccalternatives.org
> HTTP/1.1" 200 453 "-" "GNU Mailman REST client v3.3.2"
> [26/Apr/2021:12:06:25 +0000] "POST
> /3.1/members/find?list_id=ssan.lists.ccalternatives.org&subscriber=chr
> istian %40sewagesludgeactionnetwork.com HTTP/1.1" 200 1257 "-" "GNU
> Mailman REST client v3.3.2"
> [26/Apr/2021:12:06:25 +0000] "PATCH
> /3.1/members/7186cd45bde34d4fa7e7b5ab36b97272 HTTP/1.1" 204 0 "-" "GNU
> Mailman REST client v3.3.2"
> [26/Apr/2021:12:06:26 +0000] "GET
> /3.1/lists/ssan.lists.ccalternatives.org
> HTTP/1.1" 200 453 "-" "GNU Mailman REST client v3.3.2"
> [26/Apr/2021:12:06:26 +0000] "POST
> /3.1/members/find?list_id=ssan.lists.ccalternatives.org&subscriber=chr
> istian %40sewagesludgeactionnetwork.com HTTP/1.1" 200 1288 "-" "GNU
> Mailman REST client v3.3.2"
> [26/Apr/2021:12:06:26 +0000] "GET
> /3.1/lists/ssan(a)lists.ccalternatives.org/requests/count?token_owner=mo
> derato r HTTP/1.1" 200 73 "-" "GNU Mailman REST client v3.3.2"
> [26/Apr/2021:12:06:26 +0000] "GET
> /3.1/lists/ssan(a)lists.ccalternatives.org/held/count HTTP/1.1" 200 73 "-"
> "GNU Mailman REST client v3.3.2"
> [26/Apr/2021:12:06:26 +0000] "GET
> /3.1/members/7186cd45bde34d4fa7e7b5ab36b97272/preferences HTTP/1.1"
> 200 295 "-" "GNU Mailman REST client v3.3.2"
These entries don't tell anything about a post to the list. They are all
from Mailman's REST API relating to Postorius interactions with core.
However the absence of messages like
Apr 26 07:32:39 2021 (17860) ACCEPT: <message_id> and Apr 26 07:32:41 2021
(17857) HyperKitty archived message <message_id> to
https://example.com/archives/list/list_adderss/message/message_id_hash/
assuming you are looking at the correct time span, says there wasn't an
accepted list post.
Mailman's smtp.log may have more info, but the complete, raw message that
the user receives may be more helpful.
--
Mark Sapiro <mark(a)msapiro.net> The highway is for gamblers,
San Francisco Bay Area, California better use your sense - B. Dylan
_______________________________________________
Mailman-users mailing list -- mailman-users(a)mailman3.org To unsubscribe send
an email to mailman-users-leave(a)mailman3.org
https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/
4 years, 2 months

[MM3-users] Re: Problems after upgrading from bullseye to bookworm
by Odhiambo Washington
The virtualenv documentation works just fine with Bookworm AFAICT.
I didn't need to do anything out of the documentation in my test VM.
On Tue, 27 Jun 2023, 18:04 Eggert Ehmke via Mailman-users, <
mailman-users(a)mailman3.org> wrote:
> Hello Mark,
>
> thank you. I did change that entries, and now my mailman runs fine on
> Debian Bookworm.
>
> I did a complete reinstall of the venv directory to have a clean start.
> Maybe this was not
> needed. What's missing in the documentation:
> -the directiories web/logs have to be created manually with the ownership
> mailman.
> -The debian package pkg-config must be installed.
> -the package psycopg2-binary can/must be installed without version
> restriction on
> Bookworm
> Maybe this info helps some other people.
>
> Cheers, Eggert
>
> Am Montag, 26. Juni 2023, 22:22:37 CEST schrieb Mark Sapiro:
> > On 6/26/23 12:35 PM, Ken Alker wrote:
> > > I'm brand new to this, so take this with a grain of sale, but, I had a
> > > similar problem a few days ago, however, mine was "flufl.i18n>=3.2".
> > > Perhaps the same thing is happening with flufl.lock (but that didn't
> bite
> > > me).
> > >
> > > I solved my problem by following this:
> > > <https://gitlab.com/mailman/mailman/-/issues/1085> and, ultimately
> > > modifying
> > >
> "$VENV_ROOT/lib/$PYVERSION/site-packages/mailman-3.3.8.egg-info/requires.
> > > txt" per that thread (see
> > > <https://gitlab.com/mailman/mailman/-/issues/1085#note_1442207929> by
> > > Thomas Ward section called "The WORKAROUND"). Maybe you need to do the
> > > same thing, but for flufl.lock.
> > Yes, the same issue now affects flufl.lock as well as flufl.i18n. You
> > will need to change both flufl.lock->flufl_lock and
> flufl.i18n->flufl_i18n.
>
>
>
> ___________________________________________
> Mailman's content filtering has removed the
> following MIME parts from this message.
>
> Replaced multipart/alternative part with first alternative.
> _______________________________________________
> Mailman-users mailing list -- mailman-users(a)mailman3.org
> To unsubscribe send an email to mailman-users-leave(a)mailman3.org
> https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/
> Archived at:
> https://lists.mailman3.org/archives/list/mailman-users@mailman3.org/message…
>
> This message sent to odhiambo(a)gmail.com
>
2 years

[MM3-users] Re: Member Issue Discovered
by Brian Carpenter
On 10/19/20 9:04 PM, Mark Sapiro wrote:
> I suppose it could be considered a bug, but what's happening is your
> initial subscribe created a user and and address and set the user's
> preferred address to the created address. It also set the display_name
> of the address and it subscribed the user to the list or possibly the
> address to the list depending on what actually did the subscribe.
>
> When the user/address was unsubscribed, it is removed from the list's
> membership and the list was removed from the user's memberships, but the
> user and address still existed.
>
> Then when you resubscribed, the existing user/address was made a member
> of the list, but not updated so the "new" display_name was ignored. I
> think this is also the case if the original address had no display_name.
>
> You could say this is a bug and the display_name associated with this
> new subscription should replace the prior one, but what if that address
> was subscribed to other lists and didn't want the display_name changed
> on those lists.
>
> Ideally (perhaps) there could be multiple address records with the same
> email address and different display_names, but address records are keyed
> by email address, so this can't be.
>
> One workaround would be for a user who wanted to have an address with
> different display_names for different lists to have multiple addresses
> likeaddress+list1@example.com,address+list2@example.com, etc.
>
> Is this really an issue that should be fixed or just a curiosity?
No. No. No.
No one set their preferred address here at all. The first incident was
an imported list member who was not a registered user. They wanted their
real name changed to something else. The list owner tried to figured out
how to do that, found no way to do it, figured out it was just easier to
unsubscribe them, and resubscribed them to the list using a different
name. The old name showed up again. This is a bug and please fix it
soon. This has nothing to do with being subscribed to other lists. I can
probably come up with a workaround using Affinity (one of the benefits
of moving away from Postorius) but I can't imagine this not being a
serious issue as Mailman 3/Postorius is more widely adopted.
--
Brian Carpenter
Harmonylists.com
Emwd.com
4 years, 8 months

[MM3-users] Re: Mailman, etc. upgrade woes and persistent bugs
by Abhilash Raj
On Fri, Feb 12, 2021, at 11:52 AM, Mark Sapiro wrote:
> On 2/11/21 10:22 PM, hansen(a)rc.org wrote:
> > I just had my Mailman suite upgraded. When it got started, I starting receiving messages that hundreds of subscribers to the lists had been disables, including several of the list moderators. This version started supporting bounce processing, but how in the world was this upgrade allowed to act on bounces that were being collected PRIOR to enabling bounce processing??
>
>
> I'm sorry about that. It's too late now, but the avoidance is discussed
> at
> <https://lists.mailman3.org/archives/list/mailman-users@mailman3.org/thread/…>.
>
>
> > I got many angry emails, messages and phone calls asking what was going on, as they were bona fide list members. I was very surprised myself.
> >
> > I then looked at several of the disabled accounts, but the subscription info page in Postorius had no information about whether an account was enabled or disabled. Why is this not displayed???. The members can't see if their account is enabled. Is this another example of the disconnect between Mailman and Postorius?
>
>
> If the user has a Django account, she can see all that info at (e.g. for
> this list) <https://lists.mailman3.org/mailman3/accounts/subscriptions/>
> She gets there from `Mailman settings` in the dropdown under her user
> name. She can also get there via the `Manage Subscription` button on the
> list's Info page. That takes her to `List-based preferences` for the
> list. Any setting not selected there is inherited from the Address-based
> preferences or Global Mailman preferences
IIUC, I think what Allan is trying to point out is that if your account was
disabled due to bounces, there is no real visual indication about that if
you go to any of the Preferences pages (either, Global preferences,
List based preferences of address based preferences).
Even if you login as an admin and go to Member Option's view, you
won't see any visual indication about the delivery being disabled.
The is definitely a bug, caused due to the fact that "Delivery Status" field
only has two options, "Enabled" and "Disabled". Internally, this field can
have 4 values, "enabled", "by_user" (maps to "Disabled" in Postorius),
"by_admin" (means disabled by admin) and "by_bounces" (means
disabled due to bounces). So, when the value of the field is among
the last two options, it appears as "unset" with no options selected,
which unfortunately is also how it looks by default since all options
are "unset" from start.
The "fix" for this issue would be simply adding a new choice to the
delivery_status field with a caveat that it is only a Readonly option to
see that delivery is disabled due to bounces and not choosable as
a valid delivery_status value by user or admin when submitting the
form.
https://gitlab.com/mailman/postorius/-/issues/469
We could also go a step further and show it on the List's info page
when their delivery is disabled due to excessive bounce and allow
the them to re-enable it themselves without admin intervention. This
would ofcourse show only when you log into your account and go
to the list's info page, but I guess that is the first place you'd go to
debug when you get an email that your delivery was disabled?
https://gitlab.com/mailman/postorius/-/issues/470
I don't know if there are any downsides to letting users re-enable
their delivery on their own.
>
>
> > Further, even after the upgrade, the moderators still cannot access the list memberships even though all the lists are set to allow that. I would have asked the moderators to do this if this access bug had been fixed, but they can't get there.
>
> You've already reported this at
> <https://gitlab.com/mailman/postorius/-/issues/462>, and it's been
> previously reported at <https://gitlab.com/mailman/postorius/-/issues/369>.
>
>
> > As a result of these bugs, after consulting with Brian, who helped with the upgrade, I spent many hours re-enabling the several hundred accounts that had been disabled. I had to go through each email notification to find the address of a disabled account, then find the list, then the member, in Postorius, and finally enable the account (at which time Postorius DID show the enabled status).
>
>
> I'm sorry you had to go through this. The potential issue and the
> avoidances should be better documented. Unfortunately, they aren't.
>
>
> > Please, can the next upgrade include these very basic fixes/enhancements, which I requested a long time ago:
> >
> > a. The ability of moderators to see the list membership (a bug).
>
> As I note above, this is a known issue. We are a small project with very
> feew core developers, all of whom are volunteers. There is a merge
> request at <https://gitlab.com/mailman/postorius/-/merge_requests/423>
> which purports to fix
> <https://gitlab.com/mailman/postorius/-/issues/369>, but as you can see
> from the comment thread, it is not complete and the author has
> apparently disappeared.
>
> If you would like to take it over and address the deficiencies, we would
> welcome that.
>
>
> > b. The ability of members to change their addresses for all lists they are subscribed to.
>
>
> Users can add addresses to their account and can then change their
> subscribed address at (again, e.g. for this list)
> <https://lists.mailman3.org/mailman3/accounts/list-options/mailman-users.mai…>
> (Get there via the `Manage Subscription` button on the list's Info
> page.)
>
> If one is subscribed to lists via their `primary` address, one can go to
> `E-mail Addresses` in their account settings and make a new address
> `primary` and that will change all their subscriptions.
>
>
> > and further, now:
> >
> > c. That when members go to look at their subscription info, they can actually see the settings.
>
>
> They can if they go to `Mailman settings` in the dropdown or the `Manage
> Subscription` button on the list's Info page and look at all the tabs.
>
> --
> Mark Sapiro <mark(a)msapiro.net> The highway is for gamblers,
> San Francisco Bay Area, California better use your sense - B. Dylan
> _______________________________________________
> Mailman-users mailing list -- mailman-users(a)mailman3.org
> To unsubscribe send an email to mailman-users-leave(a)mailman3.org
> https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/
>
--
thanks,
Abhilash Raj (maxking)
4 years, 4 months

[MM3-users] Re: Restore/export existing Mailman lists + hyperkitty archives on a new server
by alexs@ecoscentric.com
Mark Sapiro wrote:
...
> I thing just dumping and loading the databases and copying mailman.cfg
> and the Django settings should do it. Are the domains the same on the
> new server? If not there may be issues with that. I'd need to see the
> exception and traceback to say more.
I am migrating from mailman 3.2.1 & mailman3-web 0+20180916-8 on Debian Buster to mailman 3.3.8 & mailman3-web 0+20200530-2.1 on Debian bookworm, have mailman3 and mailman3-web configured (and running on bookworm) from the initial install. But when I use the mailman3-web 0+20180916-8 database (after stopping mailman3 and mailman3-web) on bookworm, unfortunately migrate fails:
# mailman-web showmigrations
account
[X] 0001_initial
[X] 0002_email_max_length
admin
[X] 0001_initial
[X] 0002_logentry_remove_auto_add
[X] 0003_logentry_add_action_flag_choices
auth
[X] 0001_initial
[X] 0002_alter_permission_name_max_length
[X] 0003_alter_user_email_max_length
[X] 0004_alter_user_username_opts
[X] 0005_alter_user_last_login_null
[X] 0006_require_contenttypes_0002
[X] 0007_alter_validators_add_error_messages
[X] 0008_alter_user_username_max_length
[X] 0009_alter_user_last_name_max_length
[X] 0010_alter_group_name_max_length
[X] 0011_update_proxy_permissions
[X] 0012_alter_user_first_name_max_length
contenttypes
[X] 0001_initial
[X] 0002_remove_content_type_name
...
# mailman-web migrate --plan
Planned operations:
contenttypes.0001_initial
Create model ContentType
Alter unique_together for contenttype (1 constraint(s))
auth.0001_initial
Create model Permission
Create model Group
Create model User
account.0001_initial
Create model EmailAddress
Create model EmailConfirmation
account.0002_email_max_length
Alter field email on emailaddress
admin.0001_initial
Create model LogEntry
admin.0002_logentry_remove_auto_add
Alter field action_time on logentry
admin.0003_logentry_add_action_flag_choices
Alter field action_flag on logentry
contenttypes.0002_remove_content_type_name
Change Meta options on contenttype
Alter field name on contenttype
Raw Python operation
Remove field name from contenttype
...
But the migrate fails at the first operation:
# mailman-web migrate
Operations to perform:
Apply all migrations: account, admin, auth, contenttypes, django_mailman3, django_q, hyperkitty, postorius, sessions, sites, socialaccount
Running migrations:
Applying contenttypes.0001_initial...Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/django/db/backends/utils.py", line 82, in _execute
return self.cursor.execute(sql)
^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/django/db/backends/mysql/base.py", line 73, in execute
return self.cursor.execute(query, args)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/MySQLdb/cursors.py", line 209, in execute
res = self._query(query)
^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/MySQLdb/cursors.py", line 315, in _query
db.query(q)
File "/usr/lib/python3/dist-packages/MySQLdb/connections.py", line 239, in query
_mysql.connection.query(self, query)
MySQLdb._exceptions.OperationalError: (1050, "Table 'django_content_type' already exists")
...
Indeed the table django_content_type already exists on 0+20180916-8 . Apart from fields changes, there are an additional 4 tables in mailman3-web 0+20200530-2.1
I managed to import the mailman 3.2.1 database to the mailman 3.3.8 database, and all lists, subscriptions and settings looks fine.
So how can I upgrade my existing mailman3-web database?
1 year, 9 months

[MM3-users] Re: mailman3 postorius cannot retrieve template
by Wolfgang Bock
Dear Mark,
you wrote:
"When you create a template in Postorius, that uri becomes something like
`https://example.com/mailman3/api/templates/list/<list_id>/<template_name>`
which basically says get the template from Postorius, and the template if
any in var/templates is ignored."
In my case that is not true.
I get an db-entry in the mailman3 table template which doesnt lead to a
suitable link:
https://localhost/postorius/api/templates/list/testliste01.mydomain.de/list:
member:regular:footer
In the next stept it leads to a flood of entries in my syslog because django
is asking for a certificate match for "localhost":
Nov 2 11:47:49 myserver mailman3[175334]: Nov 02 11:47:49 2021 (175334)
Certificate did not match expected hostname: localhost. Certificate: ...
Letsencrypt cannot deliver this match for "localhost", it is impossible to
configurate letsencrypt to do so.
The running script must create a postgres INSERT database command which
includes the correct domain-name including the correct path
.../mailman3/api/templates .... and not ... postorius/api/....
I dont know, where is the place to correct this.
- in mailman-web.py ??
...
ALLOWED_HOSTS ... '*'
or
MAILMAN_REST_API_URL = 'http://localhost:8001'
or
POSTORIUS_TEMPLATE_BASE_URL = 'https://localhost/mailman3/'
- in mailman.cfg ??
the [paths.debian] section
the [webservice] section
- or elsewhere
Thanks in advance for your reply.
Wolfgang
-----Ursprüngliche Nachricht-----
Von: Mark Sapiro <mark(a)msapiro.net>
Gesendet: Sonntag, 31. Oktober 2021 19:15
An: mailman-users(a)mailman3.org
Betreff: [MM3-users] Re: mailman3 postorius cannot retrieve template at ...
(<no authorization>)
On 10/29/21 3:41 AM, Wolfgang Bock via Mailman-users wrote:
>
> the question is: postgres - mailman3web-postorius_emailtemplate table
> vs
> mailman3 - templates table
>
> I installed a brand new mailman3 with mailman Core 3.3.3, Api 3.1,
> Core Python 3.9.2 postgres12 nginx on debian bullseye.
>
> I created a template via postorius -> lists -> (testliste01) ->
> templates
> -> new template -> [list:member:regular:footer] and
> [list:member:digest:footer]
>
> They are shown in the postgres database mailman3 table templates:
> id name context uri username password
> 14 list:member:digest:footer testliste01.mydomain.de
> http://localhost/postorius/api/templates/list/testliste01.mydomain.de/
> list:m
> ember:digest:footer
> 15 list:member:regular:footer testliste01.mydomain.de
> http://localhost/postorius/api/templates/list/testliste01.mydomain.de/
> list:m
> ember:regular:footer
>
> First there where no templates in the /var/lib/mailman3/templates
> folder, which was empty after installation.
This is expected. That is one place where you can put custom templates.
> Later I created in /var/lib/mailman3/templates theses folders and the
> files /list/testliste01.mydomain.de/list:member:digest:footer +
> list:member:regular:footer owned by list:list 644
>
> A testmail went through but instead of the default footer no footer
> was shown.
By default Mailman searches for templates first in the var/templates
directory and then in the templates directory in the Mailman installation.
The details are described at
https://gitlab.com/mailman/mailman/-/blob/master/src/mailman/utilities/i18n.
py#L44.
However, the default search is only applied if there is matching entry for
the template name and context in the `templates` table in the database or if
the uri in the entry is a `mailman://` uri.
When you create a template in Postorius, that uri becomes something like
`https://example.com/mailman3/api/templates/list/<list_id>/<template_name>`
which basically says get the template from Postorius, and the template if
any in var/templates is ignored.
> In the sys.log I found the following error message:
> Oct 29 11:28:04 myserver mailman3[33015]: Message: 'Cannot retrieve
> template at
> http://localhost/postorius/api/templates/list/testliste01.mydomain.de/
> list:m ember:regular:footer (<no authorization>)'
So Mailman is trying to get the Postorius template. What is in the web
server logs for this retrieval?
> How can I solve this problem? What kind of authorisation is meant? list?
> restadmin?
>
> I read in
> https://docs.mailman3.org/en/latest/config-core.html#configure-templates
> ... list specific templates invar/templates/lists/LIST-ID/LC/ ...
> I guess the LC means Language Code. But in the database table templates no
> LC subdirectory is mentioned (in my case must be de).
If you delete the Postorius template, The entry in the templates table
will be removed and the search will revert to var/templates, etc.
> And I read (dont know where) .... The templates created in Postorius are
> created in the postorius_emailtemplate table in Mailman's database and
> referenced via URLs like
>
'https://example.com/mailman3/api/templates/list/<list-id>/<template-name>'.
> I.e., they are not stored in the file system. ...
>
> That's true. I found in postgres database mailman3web in the table
> mailman3web postorius_emailtemplate my
>
> id name data language created_at modified_at
> context identifier
> 15 list:member:digest:footer postorius footer digest 1x linefeed
> 2021-10-29 11:17:40.664689+02 2021-10-29 11:26:48.692628+02 list
> testliste01.mydomain.de
> 16 list:member:regular:footer postorius footer non-digest 1x
> linefeed 2021-10-29 11:18:29.166241+02 2021-10-29
11:27:24.519024+02 list
> testliste01.mydomain.de
>
> But my question is how to integrate this into the mailman3-system. The
> language isn't set either.
It is integrated. The language isn't set because you are getting the
template from Postorius and Postorius knows the language.
On 10/31/21 4:13 AM, Wolfgang Bock via Mailman-users wrote:
> regarding my mail before, here an additional information.
>
> I can show the templates with following command (anonymized):
>
https://active_domain.de/postorius/api/templates/list/testliste01.active_dom
ain.de/list:member:regular:footer
As it should be.
> The complete syslog
>
(edited and reformatted by me)
```
> --- Logging error ---
> Traceback (most recent call last): Oct 30 11:49:52 active_server
mailman3[107630]: File
"/usr/lib/python3/dist-packages/mailman/model/template.py", line 110, in get
> contents = protocols.get(actual_uri, **auth)
> File
"/usr/lib/python3/dist-packages/mailman/utilities/protocols.py", line
39, in get
> response.raise_for_status()
> File "/usr/lib/python3/dist-packages/requests/models.py", line
943, in raise_for_status
> raise HTTPError(http_error_msg, response=self)
> requests.exceptions.HTTPError: 404 Client Error: Not Found for url:
http://localhost/postorius/api/templates/list/testliste01.active_domain.de/l
ist:member:regular:footer
> During handling of the above exception, another exception occurred:
> Traceback (most recent call last):
> File "/usr/lib/python3.9/logging/__init__.py", line 430, in format
> return self._format(record)
> File "/usr/lib/python3.9/logging/__init__.py", line 426, in _format
> return self._fmt % record.__dict__
> KeyError: 't'
> During handling of the above exception, another exception occurred:
Your template is malformed. You have $ strings that are not defined as
Mailman substitution variables. See
https://docs.mailman3.org/projects/mailman/en/latest/src/mailman/rest/docs/t
emplates.html#templated-texts
--
Mark Sapiro <mark(a)msapiro.net> The highway is for gamblers,
San Francisco Bay Area, California better use your sense - B. Dylan
_______________________________________________
Mailman-users mailing list -- mailman-users(a)mailman3.org
To unsubscribe send an email to mailman-users-leave(a)mailman3.org
https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/
3 years, 8 months

[MM3-users] Re: how to unhold a hold message from a nonmmeber in hold list.
by Guillermo Hernandez (Oldno7)
El 21/4/23 a las 10:37, Odhiambo Washington escribió:
>
>
> On Fri, Apr 21, 2023 at 11:20 AM Guillermo Hernandez (Oldno7) via
> Mailman-users <mailman-users(a)mailman3.org> wrote:
>
> I'm having troubles with Django and cannot access to web admin.
>
> I need to unhold a message while figures out what is happening.
>
> Searching the mailman cli help commands didn't help me.
>
> Anyone who knows how to unhold a message, please?
>
>
> TBH, I find it a lot easier to fix the web UI than mess with the
> python shell :-)
>
> While you wait for @Mark Sapiro <mailto:mark@msapiro.net> to save you,
> you can be reading the following:
>
> https://docs.mailman3.org/projects/mailmanclient/en/latest/src/mailmanclien…
Thanks: it seems the place to do it (I didn't find it)
I'm fighting the web UI problem. It seems that something in wsgi has
changed and is no more compatible with my version of things. Error log
from apache shows:
mod_wsgi (pid=30632): Failed to exec Python script file
'/usr/local/mailman3/wsgi.py'.
mod_wsgi (pid=30632): Exception occurred processing WSGI script
'/usr/local/mailman3/wsgi.py'.
Traceback (most recent call last):
File "/usr/local/mailman3/wsgi.py", line 34, in <module>
from django.core.wsgi import get_wsgi_application
File "/usr/local/lib/python3.9/site-packages/django/core/wsgi.py", line
2, in <module>
from django.core.handlers.wsgi import WSGIHandler
File
"/usr/local/lib/python3.9/site-packages/django/core/handlers/wsgi.py",
line 3, in <module>
from django.conf import settings
File "/usr/local/lib/python3.9/site-packages/django/conf/__init__.py",
line 19, in <module>
from django.utils.deprecation import RemovedInDjango50Warning,
RemovedInDjango51Warning
File
"/usr/local/lib/python3.9/site-packages/django/utils/deprecation.py",
line 4, in <module>
from asgiref.sync import iscoroutinefunction, markcoroutinefunction,
sync_to_async
ImportError: cannot import name 'iscoroutinefunction' from
'asgiref.sync' (/usr/local/lib/python3.9/site-packages/asgiref/sync.py)
Yesterday all were running without problems, today is another day X)
>
> --
> Best regards,
> Odhiambo WASHINGTON,
> Nairobi,KE
> +254 7 3200 0004/+254 7 2274 3223
> "Oh, the cruft.", egrep -v '^$|^.*#' ¯\_(ツ)_/¯ :-)
> [How to ask smart questions:
> http://www.catb.org/~esr/faqs/smart-questions.html]
--
___________________________________________
Mailman's content filtering has removed the
following MIME parts from this message.
Content-Type: image/png
Name: firma-GHP-emails.png
Replaced multipart/alternative part with first alternative.
2 years, 2 months

[MM3-users] Re: moving individual list to different domain
by Johannes Rohr
Dear Mark,
thanks as always for your very thorough explanation. I guess, it is
simply not practical then...
Cheers,
Johannes
Am 21.03.23 um 19:11 schrieb Mark Sapiro:
> On 3/21/23 06:21, Johannes Rohr wrote:
>> Dear all,
>>
>> on mailman2 it was possible to move a list to a different domain
>> within the same mailman instance.
>>
>> I have found no information on how the same can be accomplished on
>> mailman3.
>>
>> Is this possible at all?
>
>
> In mailman 2.1, a list was identified by its name only without the
> domain and those names had to be globally unique. A site could be
> configured to support multiple virtual hosts and a list had a
> host_name attribute which could be changed if desired to assign the
> list to a different virtual host, but there couldn't be two lists with
> the same name even if they had different host names.
>
> Mailman 3 is different. In order to remove the restriction that list
> names (without the domain) had to be globally unique, in MM 3 the
> domain is part of the list name. I.e., we can now have
> list(a)example.com and list(a)example.net as two distinct lists in the
> same installation.
>
> Suppose we want to rename list(a)example.com to list(a)example.net. This
> becomes involved in Mailman 3 because it affects not only Mailman
> core, but also mail delivery and archiving. Furthermore, the list with
> fqdn_listname list(a)example.com has the list_id list.example.com. If we
> change the fqdn_listname to list(a)example.net, the list_id should
> remain list.example.com per RFC 2919 Sec. 4.
> <https://www.rfc-editor.org/rfc/rfc2919>. We can just change the
> list's mail_host attribute via REST
> <https://docs.mailman3.org/projects/mailman/en/latest/src/mailman/rest/docs/…>
> or via a database query, but this leads to confusion. I.e., a URL like
> https://example.com/mailman3/lists/list.example.com/ will still work
> but https://example.com/mailman3/lists/list@example.com/.
>
> To avoid this, we could also change the list_id, but we can't do that
> via REST as it's a read-only property, and changing the list_id says
> this is really a new list, not the same list with a new name.
>
> Also, none of this addresses archiving.
>
2 years, 3 months

[MM3-users] Re: Is there a way of recording bounce messages?
by Mohsen Masoudfar
Thank you Mark!
[EXTERNAL EMAIL]
On 9/26/23 11:29, Mohsen Masoudfar wrote:
>
> I'm dealing with the same issue. Upon reviewing the logs, I've noticed a significant number of bounced emails for a particular mailing list. Gmail users have reported not receiving emails.
> I haven't been able to locate the "munge from" information. My current setup is using Mailman 3.1.1. I read it has been introduced in 3.2.
DMARC mitigations were introduced in Mailman 3.1.0. They should be
available in 3.1.1. They were first exposed in Postorius 1.1.0.
Where are you looking for DMARC mitigations?
>> Sorry, It was my misunderstanding. DMARC mitigation is functioning well for newly created lists, even with Gmail addresses.
>> I am suspicious that Gmail might be rejecting or bouncing emails from the list due to the reputation of those lists.
>> It's worth noting that I am not the owner of the lists, but admin the Mailman3 infrastructure. My objective is to determine if our suspicious is accurate, whether Gmail is rejecting emails because of the bad reputation. We have asked Google, but no response so far.
>> I am interested to know more about the reasons behind these bounces, they are all handled by Postfix and deleted.
> The Question is what to do with Mailman 3.1.1, if the upgrade is not an option.
>
> I get in the logs messages like below with several Queue-ids:
>
> Sep 25 09:03:55 localhost postfix/smtpd[26692]: 147583E927: client=a14-93.smtp-out.amazonses.com[54.240.14.93]
> Sep 25 09:03:55 localhost postfix/cleanup[26696]: 147583E927: message-id=<0100018acb94b326-fdf39193-144e-4fdc-8faf-0d3df54eb4ee-000000(a)email.amazonses.com>
> Sep 25 09:03:55 localhost postfix/qmgr[1298]: 147583E927: from=<>, size=24934, nrcpt=1 (queue active)
> Sep 25 09:03:55 localhost postfix/lmtp[26697]: 147583E927: to=<listname-bounces@servername>, relay=127.0.0.1[127.0.0.1]:8024, delay=0.03, delays=0.01/0/0/0.01, dsn=2.0.0, status=sent (250 Ok)
> Sep 25 09:03:55 localhost postfix/qmgr[1298]: 147583E927: removed
This only says that some Amazon MTA has relayed a bounce to Mailman. It
says nothing about why the message bounced.
>> Is there a way to send them to a mailbox? Or prevent them from being deleted, so that I can look into the message body?
--
Mark Sapiro <mark(a)msapiro.net> The highway is for gamblers,
San Francisco Bay Area, California better use your sense - B. Dylan
_______________________________________________
Mailman-users mailing list -- mailman-users(a)mailman3.org
To unsubscribe send an email to mailman-users-leave(a)mailman3.org
https://nam12.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.mai…<https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/>
Archived at: https://nam12.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.mai…<https://lists.mailman3.org/archives/list/mailman-users@mailman3.org/message…>
This message sent to mmasoudf(a)aaas.org
1 year, 9 months

[MM3-users] Re: Timeout error on anonymous subscribe
by Gerald Vogt
On 24.10.24 22:09, Mark Sapiro wrote:
> On 10/23/24 23:36, vogt(a)spamcop.net wrote:
>> The only difference the last times is that with curl, the server side
>> sends the ACK for the request and milliseconds later a PSH,ACK with
>> the response headers. When it comes internally from mailman it sends
>> the ACK for the request and then 5 seconds later it sends the PSH,ACK
>> with the response headers.
>
> I'm unable to explain what's going on. You could try one more thing in
> an attempt to duplicate this outside of Mailman. Invoke the same python3
> that Mailman does - this may be in a venv or the system python3. If in a
> venv, you don't need to activate the venv, just run venv/bin/python.
>
> Then in response to Python's prompts do
> ```
> >>> import requests
> >>> res = requests.get('https://lists.example.org/mailman3/api/
> templates/list/community.lists.example.com/list:user:action:subscribe',
> timeout=5)
> ```
> and see what that does? I think it should time out because this is
> exactly what Mailman core is doing tho get the template, and if it does,
> perhaps you can determine why from this simple example.
I have tried it using the fqdn url as well as the localhost:8000 url but
in both cases requests.get immediately returns the response. The server
side pushes the response within milliseconds.
But that made me looking another time at the localhost tcpdump: I have
noticed two connections to localhost:8000 where gunicorn with
mailman_web.wsgi:application is running.
The first one is
POST /mailman3/lists/community.lists.example.com/anonymous_subscribe
the second one is
GET
/mailman3/api/templates/list/community.lists.example.com/list:user:action:subscribe
Both take 5 seconds. First the first one responds then shortly after the
second one. I have noticed that only two gunicorn processes are running
which looked like only one is a worker.
Thus I have added workers=9 (2xncore+1) to /etc/mailman3/gunicorn.conf
and restarted mailmanweb.service. Now it's working. So it must have been
some kind of deadlock situation because it only had a single worker running.
I have just followed the docs from
https://docs.mailman3.org/en/latest/install/virtualenv.html#setting-up-guni…
which doesn't mention anything about workers and I seriously don't have
a clue about gunicorn. Maybe that could be added to the docs?
Thanks for the help!
Cheers,
Gerald
8 months, 1 week

[MM3-users] Re: Multi-domain oddities in Hyperkitty and Postorius
by Jeremy Stanley
On 2023-02-15 18:35:35 -0800 (-0800), Mark Sapiro wrote:
> On 2/15/23 07:52, Jeremy Stanley wrote:
> >
> > Thanks, I'm still doing my best to wrap my brain around how Django
> > uses database migrations to create sites (seems like a very strange
> > use of a migration, I'm only accustomed to seeing them applied for
> > database schema updates).
>
> I don't think it does. There are a couple of migrations at
> django/contrib/sites/migrations, but these are only the initial creation of
> the model and an update to make the domain field unique.
>
> Why do you think it creates sites in this way.
[...]
Clearly a total misreading on my part of the Django documentation to
which you referred earlier. It talks about having to feed Django
multiple settings.py files with different SITE_ID values and running
migrate to configure them, then links to the document on migrations
which starts out explaining how to use makemigrations to create
them. I took that to mean creating and configuring Django sites from
the command line required supplying customized database migrations.
The particularly misleading bits are where it says:
"To set the correct name and domain for your project, you can
use a data migration."
"In order to serve different sites in production, you’d create a
separate settings file with each SITE_ID"
It doesn't seem to talk about using django_admin at all (or if it
does, it's not mentioned by name, maybe assuming the reader knows to
use it in order to perform the necessary steps).
Thanks for the clear examples! If these are available somewhere in
Django's documentation, I did a terrible job of searching for them.
> you need to create a domain in Postorius. Look at the code behind
> Postorius add new domain. Or you can create the domain in core via
> REST, but you then have to modify it in Postorius to associate the
> correct site.
[...]
Much appreciated, this was the other bit that was non-obvious to me.
I guess you're saying Postorius's view of domains is independent
from what's in Mailman Core, and there's no documented CLI/API for
manipulating that in Postorius so I'll need to write one based on a
reverse-engineering of its source code? Sounds doable now that I
know where to look. Thanks again!
--
Jeremy Stanley
2 years, 4 months

[MM3-users] Re: Clearing webserver cache - Nginx
by Odhiambo Washington
On Mon, Aug 5, 2024 at 9:34 PM Mark Sapiro <mark(a)msapiro.net> wrote:
> On 8/5/24 10:30, Odhiambo Washington via Mailman-users wrote:
> >
> > Actually, what I mean is that CF is proxying requests to the host named
> > m3-lists.kictanet.or.ke.
> > I do not have any configuration other than DNS proxying at CF.
>
> ```
> dig a mm3-lists.kictanet.or.ke
> ...
> mm3-lists.kictanet.or.ke. 300 IN A 172.67.167.73
> mm3-lists.kictanet.or.ke. 300 IN A 104.21.11.217
> ```
> Both of those are cloudflare IPs, and why 2?
>
Yes, those are Cloudflare IPs and I don't know why 2!
All I know is that in DNS, I created an A record for the hostname and chose
the "proxy" option in the cloudflare DNS management interface.
> > So when you talk to m3-lists.kictanet.or.ke via a browser, it's CF IP
> who you talk to and it in turn talks to the host directly.
>
> And how is that configured?
>
You add the domain - kictanet.or.ke to CF's control panel. They give you
TWO name servers. You substitute the NSes your registrar gave to your
domain for those two.
Subsequently you create A|CNAME|MX\TXT records on the CF's control panel.
You decide whether an A or CNAME record you create is proxy-ed or not. If
you proxy the record,
no one will ever get to know its real IP, but if you don't proxy, then the
dig tool above will tell you the real IP address.
> So the IP address you see in the logs is CF's IP address, not yours, not
> > mine and CF are doing some caching. That's why
> > they are requesting for expired files.
>
>
> Why is cloudfare trying to
> access /opt/mailman/mm/static/CACHE/css/output.6dab123e4897.css locally if
> all it is doing is proxying the request to the actual mailman server?
>
I don't know. However, those IPs you see in the Nginx logs, none belong to
me! I have two possible IPs - one domiciled in KE and another domiciled in
the US (when I use VPN).
--
Best regards,
Odhiambo WASHINGTON,
Nairobi,KE
+254 7 3200 0004/+254 7 2274 3223
In an Internet failure case, the #1 suspect is a constant: DNS.
"Oh, the cruft.", egrep -v '^$|^.*#' ¯\_(ツ)_/¯ :-)
[How to ask smart questions:
http://www.catb.org/~esr/faqs/smart-questions.html]
10 months, 3 weeks

[MM3-users] Re: Fresh installation mailman3-suite via "pipx" - any experiences yet?
by Stephen J. Turnbull
Mark Sapiro writes:
> > On Thu, Jan 25, 2024 at 4:43 PM Wikinaut <mail(a)tgries.de> wrote:
> >
> >> I recently found the "pipx" wrapper very useful and wanted to
> >> ask you if this could be facilitate the fresh installation of
> >> the mailman3-suite. Has anyone in the list already experiences
> >> installing mailman and mailmanweg through "pipx"?
> pipx apparently does create virtual environments. See
> https://pipx.pypa.io/stable/comparisons/
>
> The thing there that concerns me is "pipx replaces a subset of
> pip's functionality; it lets you install cli applications but NOT
> libraries that you import in your code."
>
> What does this say about the multiple dependencies that we install.
I'm pretty sure it will install dependencies. I think (everything I
say below is based on reading the README.md from pipx's pypa.io repo,
so caveat installer) that the complexity that will arise is that (for
example) a naive approach like
$ pipx install mailman
$ pipx install mailmanweb
$ pipx install postorius
$ pipx install hyperkitty
will create 4 separate venvs with 3 copies of mailmanclient, 3 copies
of django-mailman3, and two copies of Django. Besides the space
waste, there's also the small problem that mailmanweb won't have copies
of postorius and hyperkitty in its venv. :-þ pipx has an "inject"
command that allows adding other packages to a venv, but I think this
means that pipx has no great advantage over the standard way of
installing mailman into a venv.
pipx also installs stuff into the user's $HOME, specifically into
~/.local/share/pipx/venvs which I think will be kind of annoying if
you need to dig into package resources. (I expect that you will still
install configs into /etc/mailman3 and various data into
/var/lib/mailman3/var or /opt/mailman3 or whatever without a problem.)
This would only be an issue for heavy-duty customizers. This can
probably be customized.
One of the big advantages pipx touts is "look ma, no sudo". That's
not really an advantage for system daemons, though.
So bottom line is you can do it, but you'll need to study up on pipx
arcana, because Mailman is a bunch of daemon it buys you very little,
and the result won't look like any Mailman installation you've seen
described on mailman-users or StackExchange.
Steve
1 year, 5 months

[MM3-users] Re: Installing Mailman3 under a Python Virtual environment running on RHEL9
by Wild Coast
On 2024/05/22 18:25, Mark Sapiro wrote:
> On 5/22/24 11:31 AM, Andy Macheta wrote:
>> Hi Mark,
>>
>> Thanks; yes those 4 steps were performed.
>> It looks like all the web pages are displaying is just text; so
>> there's no background (apart from white) and no icons or
>> graphics....almost like CCS is not being recognized perhaps.
>
>
> If pages are not styled and you have run the collectstatic and
> compress jobs, the most likely cause is your web server not finding
> the static/ directory. See
> https://docs.mailman3.org/en/latest/install/virtualenv.html#apache-configur…
> and check your Apache logs for 404s
>
I had the same issue with the reverse proxy. Here's my final working
Debian apache2 virtualhost file:
jeff@maya:~$ cat /etc/apache2/sites-enabled/holeinthewall.conf
<VirtualHost *:80>
ServerName lists.holeinthewall.org.za
ServerAlias mail.holeinthewall.org.za
# Redirect all HTTP traffic to HTTPS
RewriteEngine On
RewriteCond %{HTTPS} off
RewriteRule (.*) https://%{SERVER_NAME}$1 [R=301,L]
</VirtualHost>
<VirtualHost *:443>
ServerAdmin webmaster(a)holeinthewall.org.za
ServerName lists.holeinthewall.org.za
# Enable SSL/TLS
SSLCertificateFile
/etc/letsencrypt/live/holeinthewall.org.za/fullchain.pem
SSLCertificateKeyFile
/etc/letsencrypt/live/holeinthewall.org.za/privkey.pem
Include /etc/letsencrypt/options-ssl-apache.conf
# Enable SSL proxying
SSLProxyEngine On
SSLProxyVerify None
SSLProxyCheckPeerCN Off
SSLProxyCheckPeerName Off
SSLProxyCheckPeerExpire Off
# Preserve the Host header
ProxyPreserveHost On
# Correct the domain in the Set-Cookie header from 127.0.0.1 to
lists.holeinthewall.org.za
ProxyPassReverseCookieDomain 127.0.0.1 lists.holeinthewall.org.za
# Serve static content directly from the filesystem
DocumentRoot /opt/mailman/web/static
Alias /static "/opt/mailman/web/static"
<Directory "/opt/mailman/web/static">
Require all granted
</Directory>
# Proxy configuration
<Proxy *>
Require all granted
</Proxy>
# Ensure X-Forwarded-Proto is set correctly
RequestHeader set X-Forwarded-Proto expr=%{REQUEST_SCHEME}
# ProxyPass configuration for specific paths
ProxyPass /static !
ProxyPass / http://127.0.0.1:8000/
ProxyPassReverse / http://127.0.0.1:8000/
ProxyPass "/mailman3" "http://127.0.0.1:8000/mailman3"
ProxyPass "/archives" "http://127.0.0.1:8000/archives"
ProxyPass "/accounts" "http://127.0.0.1:8000/accounts"
ProxyPass "/admin" "http://127.0.0.1:8000/admin"
ProxyPass "/user-profile" "http://127.0.0.1:8000/user-profile"
# Logging
ErrorLog /var/log/apache2/holeinthewall_error.log
CustomLog /var/log/apache2/holeinthewall_access.log combined
</VirtualHost>
HTH
--
Kind regards,
Jeff Brown
WildCoast WebWorx
m: +27 74 101 5170 <tel:+27%2074%20101%205170> v: +27 87 550 1210
<tel:+27%2087%20550%201210>
a: Hole in the Wall, South Africa
w: www.wildcoast.com <http://www.wildcoast.com/> e: webmaster(a)wildcoast.com
___________________________________________
Mailman's content filtering has removed the
following MIME parts from this message.
Content-Type: image/png
Name: homcljipmaiefjea.png
Replaced multipart/alternative part with first alternative.
1 year, 1 month

[MM3-users] Re: Mailman rewrite the Cc header incorrectly
by Alan So
Mark Sapiro wrote:
> Yes, the issue is closed because the fix has been merged and will be in
> Mailman Core 3.3.2.
Thanks again.
I tried to read RFC5322 again but I am not sure whether I interpret it correctly. The display-name seem allowing folding in the middle.
3.2.4
quoted-string = [CFWS]
DQUOTE *([FWS] qcontent) [FWS] DQUOTE
[CFWS]
A quoted-string is treated as a unit. That is, quoted-string is
identical to atom, semantically. Since a quoted-string is allowed to
contain FWS, folding is permitted. Also note that since quoted-pair
is allowed in a quoted-string, the quote and backslash characters may
appear in a quoted-string so long as they appear as a quoted-pair.
3.2.5
word = atom / quoted-string
phrase = 1*word / obs-phrase
3.4
display-name = phrase
A quoted-string is treated as a unit. That is, quoted-string is
identical to atom, semantically. Since a quoted-string is allowed to
contain FWS, folding is permitted. Also note that since quoted-pair
is allowed in a quoted-string, the quote and backslash characters may
appear in a quoted-string so long as they appear as a quoted-pair.
> Anyway, I really appreciate your diligence in following through
> repeatedly on this issue. Were it not for that, I wouldn't have been
> motivated to fix it. For a look at why even a trivial change is not
> trivial, see the commits at
> https://gitlab.com/mailman/mailman/-/merge_requests/652/commits.
> The
> first of these is developing good tests for the issue and then fixing
> the code so the tests pass, and the second, unanticipated one was due to
> the fact that Python 3.5 didn't maintain the original ordering of the
> addresses in Cc: so I couldn't compare against a fixed result. This is
> due to the fact that the underlying code uses dictionaries, and prior to
> Python 3.6 dictionaries didn't preserve order.
As our organization chose a free open-source software to provide service, I think it might be the only way that we can get the issue resolved since there is no official support service for a volunteer based project. Most importantly, without your detail explanation it will be really hard for us to further study the issue and file the issue in the bug tracking system.
It is a good lesson anyway since it really gives me some solid experiences about running codes with different versions of Python and it is sometimes not so trivial when developing unit tests.
5 years, 1 month

[MM3-users] Re: Mails are not archived at all -- how to check if Hyperkitty is running or not?
by Franklin Weng
Hi,
It looks like to have some clues now.
Mark Sapiro <mark(a)msapiro.net> 於 2019年10月30日 週三 13:07 寫道:
> On 10/29/19 8:21 PM, Franklin Weng wrote:
> > Yes, it is checked.
>
> Have you checked Mailman's logs - Mailman's var/logs/mailman.log in
> particular?
>
I found some hyperkitty URL error:
The default settings of base_url in mailman-hyperkitty.cfg is defined as
base_url: http://localhost/mailman/hyperkitty/
In the mailman.log there are messages like:
Oct 30 13:53:43 2019 (14259) HyperKitty failure on
http://localhost/mailman3/hyperkitty/api/mailman/archive: <!DOCTYPE HTML
PUBLIC "-//IETF//
DTD HTML 2.0//EN">
<html><head>
<title>404 Not Found</title>
</head><body>
<h1>Not Found</h1>
<p>The requested URL was not found on this server.</p>
I changed it to
base_url: https://localhost/mailman3/hyperkitty/
then the log became
File "/usr/lib/python3/dist-packages/requests
/adapters.py", line 514, in send
raise SSLError(e, request=request)
requests.exceptions.SSLError: HTTPSConnectionPool(host='localhost',
port=443): Max retries exceeded with url:
/mailman3/hyperkitty/api/mailman/archive?key=xxx (Caused by
SSLError(SSLCertVerification Error("hostname 'localhost' doesn't match '
lists.slat.org'")))
which makes sense because the SSL certificate applied from Letsencrypt is
for lists.slat.org.
If I use
base_url: https://lists.slat.org/mailman3/hyperkitty/
The log became
Oct 30 15:25:50 2019 (6256) HyperKitty failure on
https://lists.slat.org/mailman3/hyperkitty/api/mailman/urls:
<html><title>Auth required</title><body>
<h1>Authorization Required</h1>
</body></html> (401)
In my mailman-web.py:
MAILMAN_ARCHIVER_KEY = 'my-key,same as in mailman-hyperkitty.cfg'
MAILMAN_ARCHIVER_FROM = ('127.0.0.1', '::1')
Not sure what to change here.
> Do messages received from the list have an Archived-At: header?
>
Yes, but it's empty
List-Id: 測試論壇 <slat-list.lists.slat.org>
Archived-At: <>
List-Archive: <>
List-Help: <mailto:slat-list-request@lists.slat.org?subject=help>
List-Post: <mailto:slat-list@lists.slat.org>
List-Subscribe: <mailto:slat-list-join@lists.slat.org>
List-Unsubscribe: <mailto:slat-list-leave@lists.slat.org>
>
> What's in /etc/mailman3/mailman-hyperkitty.cfg? In particular does the
> [general] setting base_url define a URL that accesses hyperkitty
It seems to be the question…
and
> does the [general] setting api_key match the MAILMAN_ARCHIVER_KEY
> setting in /etc/mailman3/mailman-web.py, but note that the
> MAILMAN_ARCHIVER_KEY setting is quotes because it is a Python string
> assignment and the api_key setting is not quoted
>
Yes, it's single quoted.
Thanks for all your help!
Franklin
5 years, 8 months

[MM3-users] Re: Customise Postorius templates?
by Abhilash Raj
> On Feb 1, 2022, at 11:01 AM, Mark Sapiro <mark(a)msapiro.net> wrote:
>
> On 2/1/22 09:47, Duane Raymond wrote:
>> Hi,
>> I'm looking to do some radical customisation of the Postorius (and Hyperkitty) templates over the next 6 ish months and was wondering if there is a 'best practice' way to do this that will survive updates to MM3. I've searched around and not found much and also tested copying
>> venv/lib/python3.7/site-packages/postorius/templates/postorius/lists/summary.html
>> to
>> var/templates/lists/summary.html
>> As suggested in some posts - but it didn't seem to pick up the customisation - only customisations in the venv path worked - and they get overwritten on update.
>
>
> The var/templates directory has a specific structure and is only for custom list specific, domain specific and sitewide templates used for notifications from Mailman core. It has nothing to do with Postorius or HyperKitty templates.
>
>
>> Is there a 'best' way for this? I'd also like to eventually share them with the community and maybe add them to the repo if people want that....but for now I'll start with my own experiments. (and if there is documentation I have missed for this, let me know!)
>
>
> I don't know about a `best` way, but the way I do this is to keep all local mods as patches to the base and apply those patches as part of the upgrade process.
The best way to do this would be utilize Django’s template loader. See here[1] for the documentation on how you can do this. You want to put the path where you are putting the templates under `DIRS` option of the `TEMPLATES` section.
Do make sure that you are keeping the directory structure correct so that Django can discover them. Like, Hyperkitty’s base.html should be in `/custom/path/hyperkitty/base.html`, where `/custom/path` is what you’ve setup in DIRS setting above.
One important point to note here is that we can’t promise to not break your custom template in future, because the values passed in the template’s context is not a public or stable API. So, it is technically possible for us to remove/change the variables that are being passed. In practice, I can’t remember when was the last time I removed a variable, so this would
work better than patching since you are doing “radical customisation”, which Mark isn’t.
[1]: https://docs.djangoproject.com/en/4.0/howto/overriding-templates/
--
thanks,
Abhilash Raj (maxking)
3 years, 4 months

[MM3-users] Re: Remove old bounces in bouncedir
by Stephan Krinetzki
Mark Sapiro wrote:
> On 3/9/22 00:58, Stephan Krinetzki wrote:
> > Hello all,
> > our Mailman3 has over 7GB of bounces in its bouncedir. I noticed that some messages there are already over 3 years old. Now my question: Is there a way to remove the old bounces?
> > I don't know what you mean by bouncedir.
> If you are referring to the bounceevent table in the database, it would
> be OK to remove all the entries for which processed is True.
Ok, so i can remove there entries which are processed. For a smaller database ;)
> If you are referring to messages in Mailman's bounces queue, if these
> are not processed and removed within 15 minutes of arrival, Mailman's
> bounce runner is not running.
Well, it is the queue.Our var directory is under /opt/mailman/var and the /opt/mailman/var/queue/bounces is over 8GB big. There are *.pck messages and some of them are very old (>3 Years). The bounce seems to be running:
```
Mar 10 09:24:53 2022 (376) Member xxx@xxx already scored a bounce on list list.lists.example.com today.
Mar 10 09:25:00 2022 (376) Member xxx@xxx already scored a bounce on list list.lists.example.com today.
Mar 10 09:25:06 2022 (376) Member xxx@xxx already scored a bounce on list list.lists.example.com today.
Mar 10 09:25:12 2022 (376) Member xxx@xxx already scored a bounce on list list.lists.example.com today.
Mar 10 09:25:18 2022 (376) Member xxx@xxx already scored a bounce on list list.lists.example.com today.
Mar 10 09:25:24 2022 (376) Member xxx@xxx already scored a bounce on list list.lists.example.com today.
Mar 10 09:25:30 2022 (376) Member xxx@xxx already scored a bounce on list list.lists.example.com today.
Mar 10 09:25:36 2022 (376) Member xxx@xxx already scored a bounce on list list.lists.example.com today.
Mar 10 09:25:43 2022 (376) Member xxx@xxx already scored a bounce on list list.lists.example.com today.
Mar 10 09:25:49 2022 (376) Member xxx@xxx already scored a bounce on list list.lists.example.com today.
```
The process it self is there
```
mailman 376 99.4 19.1 6578312 6279000 ? R 09:17 10:52 venv/bin/python3 venv/bin/runner -C mailman.cfg --runner=bounces:0:1
```
(Pathes are shorted)
So i guess, there is everything fine. But the files are not deleted.
> If you are referring to bounce messages in the message store
> (var/messages/), there have been issues with those not being removed,
> but Mailman core >= 3.3.5 should clean those up.
SInce the messages are hashed or otherwise stored, i can't verify or deny this.
3 years, 3 months

[MM3-users] Re: Improve logging?
by Odhiambo Washington
On Tue, Jan 31, 2023 at 7:42 PM Mark Sapiro <mark(a)msapiro.net> wrote:
> On 1/31/23 00:40, Odhiambo Washington wrote:
> > Some entries in the log files can be very scary, while in actual sense
> they
> > are harmless.
> > Such inconsequential, but scary entiess can mess up the well-being of a
> > SysAdmin.
> > I humbly request for the logs related to posts by non-members to a MM3
> list
> > to be improved a little bit :-)
> > Here is the example in mailman.log:
> >
> > <cut>
> > Jan 31 10:03:54 2023 (92481) DISCARD: <
> > 2a1c588a6ccd47abbf57ee5fc61c9946(a)phellineconsultancy.co.ke>; ['The
> message
> > is not from a list member']
> > [31/Jan/2023:10:04:48 +0300] "GET
> > /3.1/users/1bad08f703fe4bc0a829f4bdce10fc8f HTTP/1.1" 200 253 "-" "GNU
> > Mailman REST client v3.3.5"
> > [31/Jan/2023:10:04:48 +0300] "GET
> > /3.1/users/1bad08f703fe4bc0a829f4bdce10fc8f/addresses HTTP/1.1" 200 473
> "-"
> > "GNU Mailman REST client v3.3.5"
> > Jan 31 10:18:09 2023 (92343) deque: do_confirm_verify
> > Traceback (most recent call last):
> > File
> >
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/mailman/app/workflow.py",
> > line 69, in __next__
> > return step()
> > File
> >
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/mailman/app/subscriptions.py",
> > line 476, in _step_send_confirmation
> > raise StopIteration
> > StopIteration
> > </cut>
> >
> > Is there a possibility to change the logging engine to just *fold* the
> last
> > 7 lines into "The message is not from a list member. It was discarded",
> or
> > something close?
>
> No.
>
> This entry
>
> Jan 31 10:03:54 2023 (92481) DISCARD:
> <2a1c588a6ccd47abbf57ee5fc61c9946(a)phellineconsultancy.co.ke>; ['The
> message is not from a list member']
>
> is a single entry about a discarded message.
>
> The next two are logging requests via the REST API that have nothing to
> do with the discard and are logged by a different module.
>
> The last entry with a traceback is yet another separate event. That one
> could probably be suppressed because raising StopIteration is a normal
> occurrence in workflow processing.
>
I was thiinking that they were all related.
The scary part though is the line that starts with ' Traceback'.
It's what I'd love to not-see unless there is a serious problem.
--
Best regards,
Odhiambo WASHINGTON,
Nairobi,KE
+254 7 3200 0004/+254 7 2274 3223
"Oh, the cruft.", egrep -v '^$|^.*#' ¯\_(ツ)_/¯ :-)
2 years, 5 months

[MM3-users] Re: MM2 to MM3 on debian 10
by Gelpi Andrea
Il 27/04/20 18:59, Mark Sapiro ha scritto:
> On 4/27/20 8:26 AM, Gelpi Andrea wrote:
>> Hi, on a debian 10 with MM3 I'm trying to migrate form some old MM2
>> mailing lists. I know that not all can work.
>>
>> In my old lists I have email and regular expressions in
>> reject_these_nonmembers and discard_these_nonmembers
>>
>> After importing the list all these email are in non member list.
>>
>> All these email have Delivery status enabled.
>
>
> Delivery status is not relevant for non-members and only has to do with
> receiving list posts in any case.
>
> What version of Mailman core is this? There have been changes in
> `mailman import21` that may affect this, but an address in
> `reject_these_nonmembers` should be imported as a non-member with a
> moderation action of `reject` and similarly for `discard`.
>
> Note that regexps in *_these_nonmembers should be imported into the MM 3
> legacy *_these_nonmembers attributes. Some older versions of import21
> also imported non-regexp addresses here, but that was wrong.
>
Mailman V 3.2.1
Python V 3.7.3
Postorius V 1.3.2
Hiperkitty V 1.2.2
Yes reject_these_nonmembers has a moderation action of 'reject' and the
some for discard.
>
>> Does this mean that all of them will receive any message sent to the list?
>> The moderation rule is correct, but if I understood correct Delivery
>> status should be disabled.
>
>
> Delivery status is irrelevant for non-members. Only members are
> candidates for delivery.
>
Ok, but will non-members receive the list posts or only members will?
>
>> For migration I followed this link
>> https://docs.mailman3.org/en/latest/migration.html
>>
>> To migrate archives it states to run
>>
>> python manage.py hyperkitty ...
>>
>> I cant' find a manage.py on debian 10
>
>
> manage.py is a Django generic term for the Django admin command. You
> probably want something called django-admin or similar.
>
Yes in debain 10 exists django-admin.
Now I need to understand how to use it. It asks me to load a configuration.
>
>> A search shows the only /usr/share/mailman3-web/manage.py exists.
>>
>> Is there any documentation specific for debian?
>
> That would be up to Debian.
>
--
Gelpi ing. Andrea
--------------------------------------------------------------
It took the computing power of three C-64s to fly to the Moon.
It takes a 486 to run Windows 95. Something is wrong here.
--------------------------------------------------------------
5 years, 2 months

[MM3-users] Re: Confirm and Moderate Unsubscribe Requests
by Abhilash Raj
On Wed, Oct 21, 2020, at 3:35 PM, Brian Carpenter wrote:
>
> On 10/21/20 5:39 PM, Mark Sapiro wrote:
> > On 10/21/20 12:14 PM, Brian Carpenter wrote:
> >>
> >> Well I can't dictate that to my list owners and there is no confirm
> >> token sent with the moderation notice. Why include this option in
> >> Postorius when it can't be properly handled?
> >
> > Postorius is still a work in progress. The unsubscription policies are
> > in core and are exposed in Postorius. Certainly the ability to moderate
> > an unsubscription should be in Postorius, but it isn't yet. We are an
> > all volunteer project and there aren't that many of us, and perhaps I'm
> > overreacting, but the tone of some of your recent posts seems a bit
> > demanding.
>
> I apologize. I didn't think I was coming across demanding but I am
> somewhat exasperated at some of these issues. I have a list owner who is
> now going to get a moderated request notice everyday that he can't do
> anything about it.
>
> But my question still remains: why is this option in Postorius when it
> can't be handled properly? Surely the option can be easily removed, right?
I added the option in my drive to expose every possible Mailinglist settings via Postorius and missed the fact that we weren't actually able to moderate those requests.
Yes, this option can be hidden if it doesn't work until the next stable release. I hid one of the list settings in Postorius exactly because it didn't work, but this one slipped.
>
> Is the ability to list (via the pending moderation notices tab) and
> handle (as in the List owner can decide a moderation response) an
> unsubscribe moderation request there in Mailman core so that I can
> properly address it via Affinity?
Unfortunately no, there is a bug report open for it though and I have some done some analysis on root cause[1]. The bug turned out to be a more than a trivial one and I haven't been able to get to it yet.
[1]: https://gitlab.com/mailman/mailman/-/issues/768
>
> --
>
> Brian Carpenter
> Harmonylists.com
> Emwd.com
> _______________________________________________
> Mailman-users mailing list -- mailman-users(a)mailman3.org
> To unsubscribe send an email to mailman-users-leave(a)mailman3.org
> https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/
>
--
thanks,
Abhilash Raj (maxking)
4 years, 8 months

[MM3-users] Re: User settings triggers error
by Abhilash Raj
On Tue, Jun 16, 2020, at 12:47 PM, Mark Sapiro wrote:
> On 6/16/20 12:18 PM, Mark Dadgar wrote:
> > On Jun 16, 2020, at 11:47 AM, Mark Sapiro <mark(a)msapiro.net> wrote:
> >>> File "/usr/lib/python3/dist-packages/mailmanclient/restbase/connection.py" in call
> >>> 99. raise HTTPError(url, response.status, content, response, None)
> >>
> >> And gets a 500 from core.
> >>
> >>
> >>> During handling of the above exception (HTTP Error 500: b'A server error occurred. Please contact the administrator.'), another exception occurred:
> >>
> >>
> >> Which we aren't interested in.
> >>
> >> The next step is to look in core's mailman.log to see what the rest call
> >> was and the exception and hopefully traceback the caused the 500 response.
> >
> >
> > Here’s what’s logged during that error:
> >
> > Jun 16 12:16:54 2020 (1326) 127.0.0.1 - - "GET /3.1/users/mark(a)pdc-racing.net HTTP/1.1" 200 432
> > Jun 16 12:16:54 2020 (1326) REST request handler error:
> > Traceback (most recent call last):
> > File "/usr/lib/python3/dist-packages/sqlalchemy/engine/base.py", line 1245, in _execute_context
> > self.dialect.do_execute(
> > File "/usr/lib/python3/dist-packages/sqlalchemy/engine/default.py", line 581, in do_execute
> > cursor.execute(statement, parameters)
> > psycopg2.errors.UndefinedFunction: operator does not exist: text = uuid
> > LINE 4: WHERE "user"._user_id = '05dcbeb4-b784-45eb-96f8-6f9e4b7ab6c...
> > ^
> > HINT: No operator matches the given name and argument types. You might need to add explicit type casts.
> >
> >
> > The above exception was the direct cause of the following exception:
> >
> > Traceback (most recent call last):
> > File "/usr/lib/python3.8/wsgiref/handlers.py", line 137, in run
> > self.result = application(self.environ, self.start_response)
> > File "/usr/lib/python3/dist-packages/mailman/database/transaction.py", line 50, in wrapper
> > rtn = function(*args, **kws)
> > File "/usr/lib/python3/dist-packages/mailman/rest/wsgiapp.py", line 218, in __call__
> > return super().__call__(environ, start_response)
> > File "falcon/api.py", line 232, in falcon.api.API.__call__
> > File "falcon/api.py", line 229, in falcon.api.API.__call__
> > File "falcon/api.py", line 582, in falcon.api.API._get_responder
> > File "/usr/lib/python3/dist-packages/mailman/rest/wsgiapp.py", line 131, in find
> > attribute = getattr(resource, name, MISSING)
> > File "/usr/lib/python3/dist-packages/mailman/rest/users.py", line 203, in _user
> > return user_manager.get_user_by_id(user_id)
> > File "/usr/lib/python3/dist-packages/mailman/database/transaction.py", line 85, in wrapper
> > return function(args[0], config.db.store, *args[1:], **kws)
> > File "/usr/lib/python3/dist-packages/mailman/model/usermanager.py", line 94, in get_user_by_id
> > if users.count() == 0:
> > File "/usr/lib/python3/dist-packages/sqlalchemy/orm/query.py", line 3630, in count
> > return self.from_self(col).scalar()
> > File "/usr/lib/python3/dist-packages/sqlalchemy/orm/query.py", line 3355, in scalar
> > ret = self.one()
> > File "/usr/lib/python3/dist-packages/sqlalchemy/orm/query.py", line 3325, in one
> > ret = self.one_or_none()
> > File "/usr/lib/python3/dist-packages/sqlalchemy/orm/query.py", line 3294, in one_or_none
> > ret = list(self)
> > File "/usr/lib/python3/dist-packages/sqlalchemy/orm/query.py", line 3367, in __iter__
> > return self._execute_and_instances(context)
> > File "/usr/lib/python3/dist-packages/sqlalchemy/orm/query.py", line 3392, in _execute_and_instances
> > result = conn.execute(querycontext.statement, self._params)
> > File "/usr/lib/python3/dist-packages/sqlalchemy/engine/base.py", line 982, in execute
> > return meth(self, multiparams, params)
> > File "/usr/lib/python3/dist-packages/sqlalchemy/sql/elements.py", line 287, in _execute_on_connection
> > return connection._execute_clauseelement(self, multiparams, params)
> > File "/usr/lib/python3/dist-packages/sqlalchemy/engine/base.py", line 1095, in _execute_clauseelement
> > ret = self._execute_context(
> > File "/usr/lib/python3/dist-packages/sqlalchemy/engine/base.py", line 1249, in _execute_context
> > self._handle_dbapi_exception(
> > File "/usr/lib/python3/dist-packages/sqlalchemy/engine/base.py", line 1476, in _handle_dbapi_exception
> > util.raise_from_cause(sqlalchemy_exception, exc_info)
> > File "/usr/lib/python3/dist-packages/sqlalchemy/util/compat.py", line 398, in raise_from_cause
> > reraise(type(exception), exception, tb=exc_tb, cause=cause)
> > File "/usr/lib/python3/dist-packages/sqlalchemy/util/compat.py", line 152, in reraise
> > raise value.with_traceback(tb)
> > File "/usr/lib/python3/dist-packages/sqlalchemy/engine/base.py", line 1245, in _execute_context
> > self.dialect.do_execute(
> > File "/usr/lib/python3/dist-packages/sqlalchemy/engine/default.py", line 581, in do_execute
> > cursor.execute(statement, parameters)
> > sqlalchemy.exc.ProgrammingError: (psycopg2.errors.UndefinedFunction) operator does not exist: text = uuid
> > LINE 4: WHERE "user"._user_id = '05dcbeb4-b784-45eb-96f8-6f9e4b7ab6c...
> > ^
> > HINT: No operator matches the given name and argument types. You might need to add explicit type casts.
> >
> > [SQL: SELECT count(*) AS count_1
> > FROM (SELECT "user".password AS user_password, "user".id AS user_id, "user".display_name AS user_display_name, "user"._user_id AS user__user_id, "user"._created_on AS user__created_on, "user".is_server_owner AS user_is_server_owner, "user"._preferred_address_id AS user__preferred_address_id, "user".preferences_id AS user_preferences_id
> > FROM "user"
> > WHERE "user"._user_id = %(user_id_1)s) AS anon_1]
> > [parameters: {'user_id_1': UUID('05dcbeb4-b784-45eb-96f8-6f9e4b7ab6cb')}]
> > (Background on this error at: http://sqlalche.me/e/f405)
> > Jun 16 12:16:54 2020 (1326) 127.0.0.1 - - "GET /3.1/users/05dcbeb4b78445eb96f86f9e4b7ab6cb/addresses HTTP/1.1" 500 59
> > Jun 16 12:16:54 2020 (1326) REST request handler error:
> > Traceback (most recent call last):
> > File "/usr/lib/python3/dist-packages/sqlalchemy/engine/base.py", line 1245, in _execute_context
> > self.dialect.do_execute(
> > File "/usr/lib/python3/dist-packages/sqlalchemy/engine/default.py", line 581, in do_execute
> > cursor.execute(statement, parameters)
> > psycopg2.errors.UndefinedFunction: operator does not exist: text = uuid
> > LINE 4: WHERE "user"._user_id = '05dcbeb4-b784-45eb-96f8-6f9e4b7ab6c...
> > ^
> > HINT: No operator matches the given name and argument types. You might need to add explicit type casts.
>
>
> This looks like another manifestation of the issue reported at
> https://gitlab.com/mailman/django-mailman3/-/issues/35 and
> https://lists.mailman3.org/archives/list/mailman-users@mailman3.org/message…
>
> If you are running django-mailman3 1.3.3 and haven't upgraded to
> django-mailman3 1.3.4, see the above list post for a workaround.
This is a different issue actually, seems like a bug in Core.
Interesting part of the above traceback is:
> > File "/usr/lib/python3/dist-packages/mailman/rest/users.py", line 203, in _user
> > return user_manager.get_user_by_id(user_id)
and
> > FROM "user"
> > WHERE "user"._user_id = %(user_id_1)s) AS anon_1]
> > [parameters: {'user_id_1': UUID('05dcbeb4-b784-45eb-96f8-6f9e4b7ab6cb')}]
Which makes me think that we need to call `str()` on the UUID before passing it to sqlalchemy.
I wonder why it didn't show up already on our Mailman 3 instances, which also runs postgres. Perhaps, a different version of sqlalchemy triggers this. We'd need to look more into the specific version of sqlalchemy that causes this.
Mark Dadgar, Can you please let us know the version of sqlalchemy installed with your Mailman?
--
thanks,
Abhilash Raj (maxking)
5 years

[MM3-users] Re: User settings triggers error
by Mark Dadgar
On Jun 18, 2020, at 4:08 PM, Mark Sapiro <mark(a)msapiro.net> wrote:
> On 6/18/20 3:33 PM, Mark Dadgar wrote:
>>
>> Any thoughts on how to salvage ~20 years of list archives?
>
>
> The archives shouldn't be an issue. I don't think they are involved in
> the corruption, but anyway, hopefully you still have the archive mbox
> you imported. Then for the messages since then, you should be able to
> get a mbox from hyperkitty with something like
>
> https://example.com/hyperkitty/list/listname@example.com/export/arbitrary-n…
>
> with the obvious substitutions and appropriate start and end dates.
So in trying to download the recent archives ("export/trackjunkies-new.mbox.gz?start=2019-10-10&end=2020-06-28”), I end up with an 8.5MB file with one day’s worth of posts in it (2019-10-10).
I see these errors in the mailman-web.log:
Traceback (most recent call last):
File "/usr/lib/python3.8/email/_header_value_parser.py", line 2060, in get_msg_id
token, value = get_dot_atom_text(value)
File "/usr/lib/python3.8/email/_header_value_parser.py", line 1325, in get_dot_atom_text
raise errors.HeaderParseError("expected atom at a start of "
email.errors.HeaderParseError: expected atom at a start of dot-atom-text but found ' <BYAPR02MB5976132151FF19510269C44CB3940(a)BYAPR02MB5976.namprd02.prod.outlook.com>>'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/hyperkitty/views/mlist.py", line 332, in stream_mbox
msg = email.as_message()
File "/usr/lib/python3/dist-packages/hyperkitty/models/email.py", line 175, in as_message
msg["Message-ID"] = "<%s>" % self.message_id
File "/usr/lib/python3.8/email/message.py", line 409, in __setitem__
self._headers.append(self.policy.header_store_parse(name, val))
File "/usr/lib/python3.8/email/policy.py", line 148, in header_store_parse
return (name, self.header_factory(name, value))
File "/usr/lib/python3.8/email/headerregistry.py", line 602, in __call__
return self[name](name, value)
File "/usr/lib/python3.8/email/headerregistry.py", line 197, in __new__
cls.parse(value, kwds)
File "/usr/lib/python3.8/email/headerregistry.py", line 530, in parse
kwds['parse_tree'] = parse_tree = cls.value_parser(value)
File "/usr/lib/python3.8/email/_header_value_parser.py", line 2117, in parse_message_id
token, value = get_msg_id(value)
File "/usr/lib/python3.8/email/_header_value_parser.py", line 2064, in get_msg_id
token, value = get_obs_local_part(value)
File "/usr/lib/python3.8/email/_header_value_parser.py", line 1509, in get_obs_local_part
obs_local_part[1].token_type=='dot'):
IndexError: list index out of range
[pid: 1359|app: 0|req: 12933/12933] 76.102.110.193 () {60 vars in 1504 bytes} [Sun Jun 28 19:52:57 2020] GET /mailman3/hyperkitty/list/trackjunkies@pdc-racing.net/export/trackjunkies-new.mbox.gz?start=2019-10-10&end=2020-06-28 => generated 5572382 bytes in 4271 msecs (HTTP/1.1 200) 5 headers in 203 bytes (377 switches on core 1)
Thoughts? It would be nice to salvage the last 8 months of archives.
- Mark
-----
mark(a)pdc-racing.net | 408-348-2878
5 years

[MM3-users] Re: UnicodeEncodeError: 'ascii' codec can't encode character
by Marvin Gülker
Hi,
Am 11. Dezember 2019 um 13:49 Uhr -0800 schrieb Mark Sapiro:
>OK. I have verified that this is due to
><https://bugs.python.org/issue32330> and has actually been reported as
><https://gitlab.com/mailman/mailman/issues/441> and worked around in
>Mailman by <https://gitlab.com/mailman/mailman/merge_requests/350> which
>is included in Mailman 3.2.0 and up.
Thanks, and sorry for bugging you about old versions then. I'm going to
forward the problem to Ubuntu's bugtracker then.
But I now have a different problem. I've removed all offending messages
(it were more than just one that caused the UnicodeEncodeError), but I
still can't access the page for the held messages queue. It gives an
error 500, now with a different exception in the log. I've included it
below. It looks to me that the messages haven't properly been deleted.
What I did was this: for each offending message hash
1. I ran the DELETE query
2. I deleted the file from the file system
3. I ran the delete_message() function
I originally wanted to run only the delete_message() function, but a
quick check on the DB and the file system after running it for one hash
told me that it neither deletes the message from the DB nor from the
file system. So I did everything at once. I do have a backup of both the
DB and the filesystem from before I started this, in case this broke
something.
Is there something left that I have to do now?
Here's the exception:
Dec 12 08:34:30 2019 (9570) REST request handler error:
Traceback (most recent call last):
File "/usr/lib/python3.6/wsgiref/handlers.py", line 137, in run
self.result = application(self.environ, self.start_response)
File "/usr/lib/python3/dist-packages/mailman/database/transaction.py", line 50, in wrapper
rtn = function(*args, **kws)
File "/usr/lib/python3/dist-packages/mailman/rest/wsgiapp.py", line 214, in __call__
return super().__call__(environ, start_response)
File "falcon/api.py", line 215, in falcon.api.API.__call__ (falcon/api.c:2872)
File "falcon/api.py", line 189, in falcon.api.API.__call__ (falcon/api.c:2419)
File "/usr/lib/python3/dist-packages/mailman/rest/post_moderation.py", line 167, in on_get
resource = self._make_collection(request)
File "/usr/lib/python3/dist-packages/mailman/rest/helpers.py", line 159, in _make_collection
for resource in collection]
File "/usr/lib/python3/dist-packages/mailman/rest/helpers.py", line 159, in <listcomp>
for resource in collection]
File "/usr/lib/python3/dist-packages/mailman/rest/post_moderation.py", line 157, in _resource_as_dict
resource = self._make_resource(request.id)
File "/usr/lib/python3/dist-packages/mailman/rest/post_moderation.py", line 78, in _make_resource
resource['msg'] = msg.as_string()
AttributeError: 'NoneType' object has no attribute 'as_string'
--
Blog: https://mg.guelker.eu
5 years, 6 months

[MM3-users] Re: Clearing webserver cache - Nginx
by Odhiambo Washington
On Mon, Aug 5, 2024 at 8:19 PM Mark Sapiro <mark(a)msapiro.net> wrote:
> On 8/5/24 07:04, Odhiambo Washington via Mailman-users wrote:
> > I am having an ugly-looking https://mm3-lists.kictanet.or.ke/archives/
> page
> > because of cached content:
> >
> > ```
> > 2024/08/05 17:00:31 [error] 694#694: *9562 open()
> > "/opt/mailman/mm/static/CACHE/css/output.6dab123e4897.css" failed (2: No
> > such file or directory), client: 172.70.111.39, server:
> > mm3-lists.kictanet.or.ke, request: "GET
> > /static/CACHE/css/output.6dab123e4897.css HTTP/2.0", host: "
> > mm3-lists.kictanet.or.ke", referrer: "
> > https://mm3-lists.kictanet.or.ke/archives/"
> > 2024/08/05 17:00:31 [error] 694#694: *9564 open()
> ...
> > That IP address appearing there is not my actual IP, but Cloudflare's,
> > which is acting as proxy for the site.
>
>
> I **think** you may have something like
>
> location /static/ {
> alias /opt/mailman/web/static/;
> }
>
> in nginx on cloudflare, but since cloudflare is not the Mailman server,
> /opt/mailman/web/static/ doesn't exist there.
>
Actually, what I mean is that CF is proxying requests to the host named
m3-lists.kictanet.or.ke.
I do not have any configuration other than DNS proxying at CF.
I can't be sure on how to configure this without knowing the details of
> how requests get from cloudflare to mm3-lists.kictanet.or.ke and from
> there to the wsgi server.
>
When you ping m3-lists.kictanet.or.ke, the IP you get is CFs, not the
actual IP of the host.
So when you talk to m3-lists.kictanet.or.ke via a browser, it's CF IP who
you talk to and it in turn talks to the host directly.
So the IP address you see in the logs is CF's IP address, not yours, not
mine and CF are doing some caching. That's why
they are requesting for expired files.
> However, if cloudflare just proxies the request for /static/ to the
> Mailman server and nginx on that server has the above `location`
> directive, that may do it.
>
I suppose it's possible to configure Nginx to NOT ALLOW caching of content
from the /static/ location.
Being new to Nginx, time to say hi to uncle G again.
--
Best regards,
Odhiambo WASHINGTON,
Nairobi,KE
+254 7 3200 0004/+254 7 2274 3223
In an Internet failure case, the #1 suspect is a constant: DNS.
"Oh, the cruft.", egrep -v '^$|^.*#' ¯\_(ツ)_/¯ :-)
[How to ask smart questions:
http://www.catb.org/~esr/faqs/smart-questions.html]
10 months, 3 weeks

[MM3-users] Re: A little stuck with installation of MM3 - ModuleNotFoundError: No module named 'flufl.lock'
by Odhiambo Washington
On Sat, 25 Jul 2020 at 22:11, Mark Sapiro <mark(a)msapiro.net> wrote:
> On 7/25/20 11:37 AM, Odhiambo Washington wrote:
> > On Sat, 25 Jul 2020 at 19:58, Mark Sapiro <mark(a)msapiro.net> wrote:
> >>
> >> This is a packaging glitch with the flufl modules. Remove and reinstall
> >> them.
> >>
> >> pip uninstall flufl.bounce flufl.i18n flufl.lock
> >> pip install flufl.bounce flufl.i18n flufl.lock
> >>
> >>
> > It would appear that luck isn't just on my side:
> >
> > root@gw:/opt/mailman/mm # pip uninstall flufl.bounce flufl.i18n
> flufl.lock
> ...
>
>
> You need to run these pip commands in your venv. I.e. do this
>
> > [root@gw /opt/mailman/mm]# source /opt/mailman/mm/venv/bin/activate
>
> before the pip uninstall and pip install.
> <https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/>
That has solved the problem. Thank you very much.
I have taken note of that. for my NOTES.
Finally, I have adapted your init script to get some rudimentary one that I
could use on FreeBSD.
I have to change /opt/mailman to be owned by mailman3:mailman3 (because I
have "live" MLs on this server, using mailman-2.1.34.
I am not sure if they can co-exist. I suppose they could, but what might be
the security implication, if any??
This is what the init script looks like (rudimentary!!):
(venv) [root@gw /usr/local/etc/rc.d]# less mailman3
### BEGIN INIT INFO
# Provides: GNU Mailman
# Short-Description: Mailman3 Service
# Description: service control for Mailman3
### END INIT INFO
PATH=/opt/mailman/mm/bin:/opt/mailman/mm/venv/bin:/usr/sbin:/usr/bin:/bin:/sbin:
DESC="GNU Mailman service"
DAEMON=/opt/mailman/mm/bin/mailman
NAME=mailman
USER=mailman3
GROUP=mailman3
# Needed by click
export LANG=en_US.UTF-8
# Exit if the package is not installed
[ -x "$DAEMON" ] || exit 0
# Load the VERBOSE setting and other rcS variables
#. /lib/init/vars.sh
# Define LSB log_* functions.
# Depend on lsb-base (>= 3.2-14) to ensure that this file is present
# and status_of_proc is working.
#. /lib/lsb/init-functions
case "$1" in
start)
[ "$VERBOSE" != no ] && echo "Starting $DESC" "$NAME"
# use --force to remove a stale lock.
/usr/local/bin/sudo -u $USER $DAEMON start --force
;;
stop)
[ "$VERBOSE" != no ] && echo "Stopping $DESC" "$NAME"
/usr/local/bin/sudo -u $USER $DAEMON stop
;;
status)
/usr/local/bin/sudo -u $USER $DAEMON status
;;
reopen)
/usr/local/bin/sudo -u $USER $DAEMON reopen
;;
restart)
log_daemon_msg "Restarting $DESC" "$NAME"
/usr/local/bin/sudo -u $USER $DAEMON restart
;;
*)
echo "Usage: $SCRIPTNAME {start|stop|status|reopen|restart}" >&2
exit 3
;;
esac
It does start mailman3 for sure, but also complains after a few seconds
with the message:
(venv) [root@gw /usr/local/etc/rc.d]#
*/opt/mailman/mm/venv/lib/python3.7/site-packages/mailman-3.3.2b1-py3.7.egg/mailman/rest/wsgiapp.py:180:
DeprecatedWarning: Call to deprecated function __init__(...). API class may
be removed in a future release, use falcon.App instead.*
* **kws)*
But:
(venv) [root@gw /usr/local/etc/rc.d]# ps ax | grep mailman
11677 - Is 0:00.01 /usr/local/bin/python
/usr/local/mailman/bin/mailmanctl -s -q start (python2.7)
15860 - S 0:07.86 /usr/local/bin/python
/usr/local/mailman/bin/qrunner --runner=ArchRunner:0:1 -s (python2.7)
16310 - S 0:07.43 /usr/local/bin/python
/usr/local/mailman/bin/qrunner --runner=BounceRunner:0:1 -s (python2.7)
16928 - S 0:07.07 /usr/local/bin/python
/usr/local/mailman/bin/qrunner --runner=CommandRunner:0:1 -s (python2.7)
17335 - S 0:07.47 /usr/local/bin/python
/usr/local/mailman/bin/qrunner --runner=IncomingRunner:0:1 -s (python2.7)
17975 - S 0:07.02 /usr/local/bin/python
/usr/local/mailman/bin/qrunner --runner=NewsRunner:0:1 -s (python2.7)
18419 - S 0:20.06 /usr/local/bin/python
/usr/local/mailman/bin/qrunner --runner=OutgoingRunner:0:1 -s (python2.7)
19015 - S 0:07.13 /usr/local/bin/python
/usr/local/mailman/bin/qrunner --runner=VirginRunner:0:1 -s (python2.7)
19131 - I 0:00.15 /usr/local/bin/python
/usr/local/mailman/bin/qrunner --runner=RetryRunner:0:1 -s (python2.7)
27273 - Is 0:01.64 /opt/mailman/mm/venv/bin/python
/opt/mailman/mm/venv/bin/master --force -C /opt/mailman/mm/mailman.cfg
(python3.7)
28526 - S 0:01.70 /opt/mailman/mm/venv/bin/python
/opt/mailman/mm/venv/bin/runner -C /opt/mailman/mm/mailman.cfg
--runner=archive:0:1 (python3.7)
28627 - I 0:01.77 /opt/mailman/mm/venv/bin/python
/opt/mailman/mm/venv/bin/runner -C /opt/mailman/mm/mailman.cfg
--runner=bounces:0:1 (python3.7)
28988 - S 0:01.70 /opt/mailman/mm/venv/bin/python
/opt/mailman/mm/venv/bin/runner -C /opt/mailman/mm/mailman.cfg
--runner=command:0:1 (python3.7)
29341 - S 0:01.69 /opt/mailman/mm/venv/bin/python
/opt/mailman/mm/venv/bin/runner -C /opt/mailman/mm/mailman.cfg
--runner=in:0:1 (python3.7)
29978 - S 0:01.68 /opt/mailman/mm/venv/bin/python
/opt/mailman/mm/venv/bin/runner -C /opt/mailman/mm/mailman.cfg
--runner=lmtp:0:1 (python3.7)
30843 - S 0:01.70 /opt/mailman/mm/venv/bin/python
/opt/mailman/mm/venv/bin/runner -C /opt/mailman/mm/mailman.cfg
--runner=nntp:0:1 (python3.7)
31541 - S 0:01.70 /opt/mailman/mm/venv/bin/python
/opt/mailman/mm/venv/bin/runner -C /opt/mailman/mm/mailman.cfg
--runner=out:0:1 (python3.7)
31675 - S 0:01.70 /opt/mailman/mm/venv/bin/python
/opt/mailman/mm/venv/bin/runner -C /opt/mailman/mm/mailman.cfg
--runner=pipeline:0:1 (python3.7)
32181 - S 0:01.77 /opt/mailman/mm/venv/bin/python
/opt/mailman/mm/venv/bin/runner -C /opt/mailman/mm/mailman.cfg
--runner=rest:0:1 (python3.7)
33166 - I 0:01.65 /opt/mailman/mm/venv/bin/python
/opt/mailman/mm/venv/bin/runner -C /opt/mailman/mm/mailman.cfg
--runner=retry:0:1 (python3.7)
33694 - S 0:01.70 /opt/mailman/mm/venv/bin/python
/opt/mailman/mm/venv/bin/runner -C /opt/mailman/mm/mailman.cfg
--runner=virgin:0:1 (python3.7)
34600 - S 0:01.69 /opt/mailman/mm/venv/bin/python
/opt/mailman/mm/venv/bin/runner -C /opt/mailman/mm/mailman.cfg
--runner=digest:0:1 (python3.7)
41250 - S 0:00.01 /opt/mailman/mm/venv/bin/python
/opt/mailman/mm/venv/bin/runner -C /opt/mailman/mm/mailman.cfg
--runner=rest:0:1 (python3.7)
41533 - S 0:00.01 /opt/mailman/mm/venv/bin/python
/opt/mailman/mm/venv/bin/runner -C /opt/mailman/mm/mailman.cfg
--runner=rest:0:1 (python3.7)
98450 - I 0:00.45 httpd: mailman-web (httpd)
59886 0 S+ 0:00.00 grep mailm
Assuming that I am using mod_wsgi with Apache, and that I have configured
apache right using
https://wiki.list.org/DOC/Mailman%203%20installation%20experience?action=At…
..
should I be able to access the MM3 web UI??
At that point, I am feeling somewhat confused as to what to try next.
(venv) [root@gw /opt/mailman/mm/var/logs]# less mailman.log
Jul 25 22:53:16 2020 (40670) Master started
Jul 25 22:53:18 2020 (42036) bounces runner started.
Jul 25 22:53:18 2020 (45205) out runner started.
Jul 25 22:53:19 2020 (41191) archive runner started.
Jul 25 22:53:19 2020 (46670) retry runner started.
Jul 25 22:53:19 2020 (44567) nntp runner started.
Jul 25 22:53:19 2020 (43069) in runner started.
Jul 25 22:53:19 2020 (46960) virgin runner started.
Jul 25 22:53:20 2020 (45720) pipeline runner started.
Jul 25 22:53:20 2020 (47326) digest runner started.
Jul 25 22:53:20 2020 (43755) lmtp runner started.
Jul 25 22:53:20 2020 (45922) rest runner started.
[2020-07-25 22:53:20 +0300] [45922] [INFO] Starting gunicorn 20.0.4
[2020-07-25 22:53:20 +0300] [45922] [INFO] Listening at:
http://127.0.0.1:8001 (45922)
[2020-07-25 22:53:20 +0300] [45922] [INFO] Using worker: sync
[2020-07-25 22:53:20 +0300] [54732] [INFO] Booting worker with pid: 54732
[2020-07-25 22:53:20 +0300] [55467] [INFO] Booting worker with pid: 55467
Jul 25 22:53:21 2020 (42743) command runner started.
How do I access the web UI for MM3 now?
Thanks in advance.
--
Best regards,
Odhiambo WASHINGTON,
Nairobi,KE
+254 7 3200 0004/+254 7 2274 3223
"Oh, the cruft.", grep ^[^#] :-)
4 years, 11 months

[MM3-users] Re: postfix malformed address with confirm replies
by Stephen Mats Mats
> On Feb 28, 2021, at 01:32, Stephen J. Turnbull <turnbull.stephen.fw(a)u.tsukuba.ac.jp> wrote:
>
> Mark Sapiro writes:
>> On 2/27/21 4:36 AM, Stephen J. Turnbull wrote:
>
>>> is legal, and I think that most servers will accept it, but RFC
>>> 5321 sets a limit of 64 octets on mailboxes[1], and your
>>> confirmation mailbox is 67 octets.
>>
>> Since the -confirm+<token> part is fixed at 49 octets, this would imply
>> a limit in list names of 15 octets. Ouch!
>
> I'm pretty sure we would have run into this before, if there were a
> lot of servers out there imposing this limit. 15 octets is pretty
> darn short, there are probably quite a few list names out there longer
> than that. Not to mention that the RFC itself says "you SHOULD NOT be
> a jerk about this". :-) So I don't think this is a big problem in
> practice, and I hope Steve can reconfigure the obstructive server to
> not be so picky.
>
To be clear the 'obstructive server’ is mailman-core. :)
[ec2-user@ip-172-31-18-xxx ~]$ telnet 172.19.199.2 8024
Trying 172.19.199.2...
Connected to 172.19.199.2.
Escape character is '^]'.
220 mailman-core GNU Mailman LMTP runner 2.0
LHLO ip-172-31-18-xxx.us-west-2.compute.internal
250-mailman-core
250-SIZE 33554432
250-8BITMIME
250 HELP
MAIL FROM:<stephen.s.w.matsmats(a)gmail.com>
250 OK
RCPT TO:<matsmats-mm3-test1-confirm+d6f77a2572ef55a8b2c4ca0d77de8493fbb55856(a)mm3.aca-aws.s.uw.edu>
553 5.1.3 Error: malformed address
RCPT TO:<matsmats-mm3-test1-confirm+d6f77a2572ef55a8b2c4ca0d77de8493fbb55(a)mm3.aca-aws.s.uw.edu>
250 OK
quit
221 Bye
Didn’t really dig but my guess would be the LMTP from aiosmtpd.lmtp is actually throwing the 553.
For a bit of context, of the 25,801 mailman2 lists we have here at University of Washington 5,211 have names longer than 15 characters (we don’t have any lists with multibyte characters in their names). Our longest list name is 33 characters. I didn’t dump every config to see the number of lists that subscribe_policy set to confirm or confirm and approve. But I expect it’s a small minority.
steve
> For Mailman, I doubt we need a full SHA1 (?) for the purpose. We can
> truncate the thing, probably opportunistically (ie, so the whole
> confirmation mailbox fits in 64 octets, or we could even parse the
> bounce message and resend only if we run into a problem).
>
> Steve
> _______________________________________________
> Mailman-users mailing list -- mailman-users(a)mailman3.org
> To unsubscribe send an email to mailman-users-leave(a)mailman3.org
> https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/
4 years, 4 months

[MM3-users] Non-ascii characters missing from Pipermail archive txt and gz downloads
by Mark Dale
Mailman 2.1.34
Debian 10
Postfix
Hi
I'm hoping someone can shine a light on character encoding issue I've encountered.
A plain-text email with non-ascii characters in the body gets posted to the list.
As per Mark Sapiro's guide I've captured the incoming message to file.
- https://www.mail-archive.com/mailman-users@python.org/msg73469.html
The message is received by Mailman with the non-ascii characters displaying correctly.
The header of that message has:
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101
Thunderbird/78.9.0
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Language: en-AU
Content-Transfer-Encoding: 8bit
In the list's mbox file and archive webpage, the message displays the non-ascii characters correctly.
In the archive's downloaded .txt (and also .gz) file, the non-ascii characters are missing and displayed as "?".
I've copied the message text in below, from both the correct one from the email and the erroneous .txt file. Hopefully they won't get scrambled up when I send this.
Any advice on getting the non-ascii characters written into the archive .txt file would be gratefully received.
Thanks,
Mark
=== Message text as okay in mbox and as shown on the archive webpage ===
If one goes by the definition of veḷippaṭai as given in the Tamil Lexicon that the meaning of an ambiguous word should be disambiguated by a qualifying word, then aruvi āmpal does not conform to that definition since in the case of aruvi āmpal in Patiṟṟuppattu 63, aruvi is really made up of aru+vi, a compound. Moreover, the expression aṭai aṭuppu aṟiyā is already there to clarify that āmpal is a number and not a flower. Thus, aruvi simply provides information in addition to aṭai aṭuppu aṟiyā that āmpal is not a flower. The modern commentator Aruḷampalavaṉār also does not call it veḷippaṭai.
===
=== Message text with missing characters in te archive's txt and gz downloads ==
If one goes by the definition of ve?ippa?ai as given in the Tamil Lexicon that the meaning of an ambiguous word should be disambiguated by a qualifying word, then aruvi ?mpal does not conform to that definition since in the case of aruvi ?mpal in Pati??uppattu 63, aruvi is really made up of aru+vi, a compound. Moreover, the expression a?ai a?uppu a?iy? is already there to clarify that ?mpal is a number and not a flower. Thus, aruvi simply provides information in addition to a?ai a?uppu a?iy? that ?mpal is not a flower. The modern commentator Aru?ampalava??r also does not call it ve?ippa?ai.
===
4 years, 2 months

[MM3-users] Re: Message-Footer after migrating to Mailman3
by Abhilash Raj
> On Jul 9, 2021, at 9:15 AM, christopher.claus(a)tgcamberg1848.de wrote:
>
> Mark Sapiro wrote:
>>> ERROR 2021-05-24 16:22:22,895 1648 django.security.DisallowedHost Invalid HTTP_HOST header: 'tgc_mailman_web:8000'. The domain name provided is not valid according to RFC 1034/1035.
>>> WARNING 2021-05-24 16:22:22,896 1648 django.request Bad Request: /postorius/api/templates/list/homepage.gruppe.tgcamberg1848.de/list:member:regular:footer
>>> It appears you created the new template with Postorius, but there is an
>> issue for Postorius templates. Possibly your Django setting for
>> POSTORIUS_TEMPLATE_BASE_URL needs to be adjusted.
>>> Obviously I have a problem with the hostname. I set
>>> [code]
>>> POSTORIUS_TEMPLATE_BASE_URL=http://tgc_mailman_web:8000
>>> [/code]
>>> where tgc_mailman_web is my container name. This URL ist stored in the DB-table "template" for the name=list:member:regular:footer. A call to my fqdn or to localhost
>>> [code]
>>> wget http://localhost:8000/postorius/api/templates/list/homepage.gruppe.tgcamberg...
>>> [/code]
>>> will return the footer itself - this works fine. Therefore, should i set POSTORIUS_TEMPLATE_BASE_URL to http://localhost:8000?
>>> If that works, yes.
>
> Hi Mark,
>
> thanks for your reply and excuse my delay. I was very busy in the last weeks but made some tests. Newly created templates with POSTORIUS_TEMPLATE_BASE_URL=http://localhost:8000 did not work. I changed it to my fqdn - at the moment I am able to access the template via this URl (e.G. http://lists.example.de:8000/postorius/api/templates/list/homepage.lists.ex…)
> But if I try to send an email I got the following error:
You want the URL at which Postorius (postorius) is available from Core (mailman-core container). The default for that in the container images is set to http://mailman-web:8000. Does that not work for you?
If you want to verify, you want to exec into the Core’s container (`docker exec -it mailman-core bash`) and see if you can curl the URL from inside there. If you are using the default docker-compose-postorius.yaml then there is a /etc/hosts entry created by docker for the mailman-web container, hence `http://mailman-web:8000` works there (but it won’t work on the host, since docker doesn’t modify the host’s /etc/hosts).
There might also be a bug in play here which would cause such connection refused errors when subscribing/unsubscribing when there was a template configured for the list. Is that the case for you or are you seeing always when trying to send the email (which would imply that the Web container simply isn’t reachable from Core).
--
thanks,
Abhilash Raj (maxking)
3 years, 10 months

[MM3-users] Re: Core, Hyperkitty and Postorius releases
by Odhiambo Washington
On Sat, May 15, 2021 at 12:24 AM Abhilash Raj <maxking(a)asynchronous.in>
wrote:
>
>
> On Fri, May 14, 2021, at 2:16 PM, Odhiambo Washington wrote:
> > On Sat, May 15, 2021 at 12:01 AM Mark Sapiro <mark(a)msapiro.net> wrote:
> >
> > > On 5/14/21 1:54 PM, Odhiambo Washington wrote:
> > > >
> > > > /usr/local/include/sass
> > > >
> > > > That is the only thing found that is in the base system.
> > >
> > > And that's the one you want. What is it's mode?
> > >
> >
> > root@gw:/usr/home/wash # ls -al /usr/local/include/sass
> > total 104
> > drwxr-xr-x 2 root wheel 512 Apr 16 16:49 .
> > drwxr-xr-x 176 root wheel 10240 Apr 19 18:05 ..
> > -rw-r--r-- 1 root wheel 2369 Apr 8 11:08 base.h
> > -rw-r--r-- 1 root wheel 10742 Apr 8 11:08 context.h
> > -rw-r--r-- 1 root wheel 6632 Apr 8 11:08 functions.h
> > -rw-r--r-- 1 root wheel 6489 Apr 8 11:08 values.h
> > -rw-r--r-- 1 root wheel 198 Apr 8 11:08 version.h
> >
> > I imagined I needed an executable.
>
> This sounds like a result of you running `pip3 install sass`, probably
> with sudo
> which failed mid-way due to the exception you posted above.
>
Closer to the truth! It failed. I was running this from within the
virtualenv.
> Which OS are you using?
FreeBSD.
> On debian/ubuntu, you can install:
>
> sudo apt install sassc
>
Do I need to install sassc in the base OS or in the virtualenv?
> I am not exactly sure how it got removed during your upgrade
> to the new version of Mailman since it shouldn't affect your system
> packages.
>
The funny part is my MM3 used to run. Mark took so much hand-holding for me
to get it running.
Then one day I used the update process and things got hosed.
The happy part is that I had not put any production lists on MM3 as I
hadn't developed the confidence of managing it.
Did you install Mailman initially using system packages or instructions
> provided at [1]?
>
> [1]:
> https://docs.mailman3.org/en/latest/install/virtualenv.html#virtualenv-inst…
No. I relied on
https://wiki.list.org/DOC/Mailman%203%20installation%20experience. This is
way back!
Your new link is recent, no?
--
Best regards,
Odhiambo WASHINGTON,
Nairobi,KE
+254 7 3200 0004/+254 7 2274 3223
"Oh, the cruft.", egrep -v "^$|^.*#" :-)
4 years, 1 month

[MM3-users] Re: Errors while importing mm2 list archives - SOLVED
by Odhiambo Washington
On Tue, Dec 20, 2022 at 9:50 AM Odhiambo Washington <odhiambo(a)gmail.com>
wrote:
>
>
> On Tue, Dec 20, 2022 at 3:52 AM Mark Sapiro <mark(a)msapiro.net> wrote:
>
>> On 12/17/22 23:22, Odhiambo Washington wrote:
>> >
>> > I have dropped the DB, recreated, ...
>>
>> When you created the DB did you specify `CHARACTER SET utf8mb4`, e.g.
>>
>> CREATE DATABASE mailmansuite CHARACTER SET utf8mb4
>>
>
> Yes. That is what I do at the minimum for my databases unless specific
> instructions exist against it.
> So it seems like I have done everything that is commonly expected, but the
> import still fails on several messages.
>
It turns out that all this time I was barking up the wrong tree!
I was having all my modifications in /etc/mailman3/*.
When I did run 'mailman info', the information that came out is that
mailman was actually reading /opt/mailman/mm/mailman.cfg
I then just moved all the files I had put in /etc/mailman3/ to
/opt/mailman/mm/.
There is a WARNING on
https://docs.list.org/en/latest/install/virtualenv.html#virtualenv-install
which says one must create the config file as /etc/mailman3/mailman.cfg
How to force mailman to read that file is something I haven't understood,
but turns out to be what has taken me days trying to get things right.
Ultimately, when I did the import, there was only one email from the
archives that failed to be imported - which I honestly don't mind, but
maybe there is a solution for this
"'utf-8' codec can't encode character '\udcae' in position 331: surrogates
not allowed" ??
(venv) [mailman@gw ~/mm]$ /opt/mailman/mm/bin/django-admin
hyperkitty_import -l kictanet(a)lists.kictanet.or.ke
/usr/local/mailman2/archives/private/kictanet.mbox/kictanet.mbox
Importing from mbox file
/usr/local/mailman2/archives/private/kictanet.mbox/kictanet.mbox to
kictanet(a)lists.kictanet.or.ke
21%*Failed adding message
<1260802782.6596.1350003565(a)webmail.messagingengine.com
<1260802782.6596.1350003565(a)webmail.messagingengine.com>>: 'utf-8' codec
can't encode character '\udcae' in position 331: surrogates not allowed*
Computing thread structure
Synchronizing properties with Mailman
915 emails left to refresh, checked 0
767 emails left to refresh, checked 0
Warming up cache
The full-text search index is not updated for this list. It will not be
updated by the 'minutely' incremental update job. To update the index for
this list, run the Django admin command with arguments
'update_index_one_list kictanet(a)lists.kictanet.or.ke'.
(venv) [mailman@gw ~/mm]$
--
Best regards,
Odhiambo WASHINGTON,
Nairobi,KE
+254 7 3200 0004/+254 7 2274 3223
"Oh, the cruft.", egrep -v '^$|^.*#' ¯\_(ツ)_/¯ :-)
2 years, 6 months

[MM3-users] Re: "Delete this thread" -> 'HTTP-500 -> NoneType' object has no attribute 'all'
by Simon Liebold
Am 28.05.2017 um 21:16 schrieb Mark Sapiro:
>
> I just tested this on another list on this server. and both 'delete
> message' and 'delete thread' worked for me with the latest release
> Hyperkitty 1.1.0, django_mailman3 1.1.0 and Django-1.10.7.
>
> Did you get to the confirmation page and then get the 500 or did the 500
> come before getting the confirmation page? Is there a full traceback in
> mailman_web.log?
>
I didn't find a 'delete message' button. But "Delete this thread" went
straight to the 500. Both, Hyperkitty and django-mailman are up-to-date
with master.
ERROR 2017-05-28 13:04:14,496 29835 django.request Internal Server
Error:
/hyperkitty/list/simsimmer@lists.simonliebold.de/thread/4I2TRZTFXMMH2XRQAS73IAEIYROFE5YM/delete
Traceback (most recent call last):
File
"/opt/mailman/venv-2.7/local/lib/python2.7/site-packages/Django-1.11rc1-py2.7.egg/django/core/handlers/exception.py",
line 41, in inner
response = get_response(request)
File
"/opt/mailman/venv-2.7/local/lib/python2.7/site-packages/Django-1.11rc1-py2.7.egg/django/core/handlers/base.py",
line 249, in _legacy_get_response
response = self._get_response(request)
File
"/opt/mailman/venv-2.7/local/lib/python2.7/site-packages/Django-1.11rc1-py2.7.egg/django/core/handlers/base.py",
line 187, in _get_response
response = self.process_exception_by_middleware(e, request)
File
"/opt/mailman/venv-2.7/local/lib/python2.7/site-packages/Django-1.11rc1-py2.7.egg/django/core/handlers/base.py",
line 185, in _get_response
response = wrapped_callback(request, *callback_args, **callback_kwargs)
File
"/opt/mailman/venv-2.7/local/lib/python2.7/site-packages/Django-1.11rc1-py2.7.egg/django/contrib/auth/decorators.py",
line 23, in _wrapped_view
return view_func(request, *args, **kwargs)
File "/opt/mailman/hyperkitty/hyperkitty/lib/view_helpers.py", line
141, in inner
return func(request, *args, **kwargs)
File "/opt/mailman/hyperkitty/hyperkitty/views/message.py", line 306,
in delete
form = MessageDeleteForm(initial={"email": initial})
File
"/opt/mailman/venv-2.7/local/lib/python2.7/site-packages/Django-1.11rc1-py2.7.egg/django/forms/forms.py",
line 96, in __init__
self.fields = copy.deepcopy(self.base_fields)
File "/usr/lib/python2.7/copy.py", line 190, in deepcopy
y = _reconstruct(x, rv, 1, memo)
File "/usr/lib/python2.7/copy.py", line 328, in _reconstruct
args = deepcopy(args, memo)
File "/usr/lib/python2.7/copy.py", line 163, in deepcopy
y = copier(x, memo)
File "/usr/lib/python2.7/copy.py", line 237, in _deepcopy_tuple
y.append(deepcopy(a, memo))
File "/usr/lib/python2.7/copy.py", line 163, in deepcopy
y = copier(x, memo)
File "/usr/lib/python2.7/copy.py", line 230, in _deepcopy_list
y.append(deepcopy(a, memo))
File "/usr/lib/python2.7/copy.py", line 163, in deepcopy
y = copier(x, memo)
File "/usr/lib/python2.7/copy.py", line 230, in _deepcopy_list
y.append(deepcopy(a, memo))
File "/usr/lib/python2.7/copy.py", line 174, in deepcopy
y = copier(memo)
File
"/opt/mailman/venv-2.7/local/lib/python2.7/site-packages/Django-1.11rc1-py2.7.egg/django/forms/models.py",
line 1168, in __deepcopy__
result.queryset = self.queryset.all()
AttributeError: 'NoneType' object has no attribute 'all'
Simon
8 years, 1 month

[MM3-users] Re: Database problem after system upgrade
by Odhiambo Washington
On Wed, Nov 15, 2023 at 11:34 AM Lars Bjørndal <lars(a)lamasti.net> wrote:
> Thanks a lot.
>
> [Odhiambo]
>
> > From the above output, I'd try two things:
> >
> > 1. Is the database really running?
> >
> > ```
> > $ sudo -u postgres psql
> > ```
> >
> > 2. Can mailman connect to the database:
> >
> > ```
> > psql -h localhost -U mailman -d mailman -W
> > ```
> >
> > What does those two commands give you?
>
> I found that I did need to change the pg_hba.conf to get authentication to
> work.
>
> When I no start Mailman, I get the following:
>
> Traceback (most recent call last):
> File "/opt/mailman3/venv/bin/mailman", line 8, in <module>
> sys.exit(main())
> ^^^^^^
> File "/opt/mailman3/venv/lib64/python3.11/site-packages/click/core.py",
> line 1130, in __call__
> return self.main(*args, **kwargs)
> ^^^^^^^^^^^^^^^^^^^^^^^^^^
> File "/opt/mailman3/venv/lib64/python3.11/site-packages/click/core.py",
> line 1055, in main
> rv = self.invoke(ctx)
> ^^^^^^^^^^^^^^^^
> File
> "/opt/mailman3/venv/lib64/python3.11/site-packages/mailman/bin/mailman.py",
> line 69, in invoke
> return super().invoke(ctx)
> ^^^^^^^^^^^^^^^^^^^
> File "/opt/mailman3/venv/lib64/python3.11/site-packages/click/core.py",
> line 1657, in invoke
> return _process_result(sub_ctx.command.invoke(sub_ctx))
> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
> File "/opt/mailman3/venv/lib64/python3.11/site-packages/click/core.py",
> line 1404, in invoke
> return ctx.invoke(self.callback, **ctx.params)
> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
> File "/opt/mailman3/venv/lib64/python3.11/site-packages/click/core.py",
> line 760, in invoke
> return __callback(*args, **kwargs)
> ^^^^^^^^^^^^^^^^^^^^^^^^^^^
> File
> "/opt/mailman3/venv/lib64/python3.11/site-packages/click/decorators.py",
> line 26, in new_func
> return f(get_current_context(), *args, **kwargs)
> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
> File
> "/opt/mailman3/venv/lib64/python3.11/site-packages/mailman/commands/cli_control.py",
> line 91, in start
> status, lock = master_state()
> ^^^^^^^^^^^^^^
> File
> "/opt/mailman3/venv/lib64/python3.11/site-packages/mailman/bin/master.py",
> line 104, in master_state
> os.kill(pid, 0)
> PermissionError: [Errno 1] Operation not permitted
>
>
> But which operation are not permitted, how to find the cause?
>
That message is cryptic to me, but @Mark Sapiro <mark(a)msapiro.net> might
know.
Could you please see if there are stale lock files in
/opt/mailman3/var/locks/ that could be preventing mailman3 from starting?
If there are two files there, delete them and try starting mailman3 again.
Beyond that possibility, I now remain clueless :)
--
Best regards,
Odhiambo WASHINGTON,
Nairobi,KE
+254 7 3200 0004/+254 7 2274 3223
"Oh, the cruft.", egrep -v '^$|^.*#' ¯\_(ツ)_/¯ :-)
[How to ask smart questions:
http://www.catb.org/~esr/faqs/smart-questions.html]
1 year, 7 months

[MM3-users] Re: Installation Wooes
by Samir Faci
I manually patched up the bug since It seems it only occurs once or twice
in the code base.
Here's my next question. Hopefully this isn't off topic, but trying to get
postfix to work with mailman and I keep on getting relay denied issues.
/var/log/mailman/smtp.log
May 04 02:06:20 2020 (136767)
<158855797827.136760.10970401726993928773@lists> smtp to
booh(a)lists.domain.org for 1 recips, completed in 0.016954421997070312
seconds
May 04 02:06:20 2020 (136767)
<158855797827.136760.10970401726993928773@lists> post to
booh(a)lists.domain.org from booh-owner(a)lists.domain.org, 5180 bytes
May 04 02:06:20 2020 (136765) ('198.199.98.177', 42734) Data: b'QUIT'
May 04 02:06:20 2020 (136765) ('198.199.98.177', 42734) connection lost
May 04 02:06:20 2020 (136765) Connection lost during _handle_client()
May 04 02:06:21 2020 (136767)
<158855797827.136760.10970401726993928773@lists> recipients refused: {'
csgeek(a)domain.com': (554, b'5.7.1 <csgeek(a)domain.com>: Relay access
denied')}
May 04 02:06:21 2020 (136767)
<158855797827.136760.10970401726993928773@lists> smtp to
booh(a)lists.domain.org for 1 recips, completed in 0.022742748260498047
seconds
May 04 02:06:21 2020 (136767)
<158855797827.136760.10970401726993928773@lists> post to
booh(a)lists.domain.org from booh-owner(a)lists.geekbeacon.org, 5496 bytes, 1
failures
May 04 02:06:21 2020 (136767)
<158855797827.136760.10970401726993928773@lists> delivery to
csgeek(a)domain.com failed with code 554, b'5.7.1 <csgeek(a)domain.com>: Relay
access denied'
These are the changes I have in postfix that seem relevant.
/etc/postfix/master.cf
mailman unix - n n - - pipe
flags=FR user=list argv=/usr/lib/mailman/bin/postfix-to-mailman.py
${nexthop} ${user}
/etc/postfix/main.cf
compatibility_level = 2
recipient_delimiter = +
unknown_local_recipient_reject_code = 550
owner_request_special = no
transport_maps = hash:/var/lib/mailman3/data/postfix_lmtp
local_recipient_maps = $alias_maps hash:/var/lib/mailman3/data/postfix_lmtp
relay_domains = hash:/var/lib/mailman3/data/postfix_domains
smtpd_relay_restrictions = permit_mynetworks permit_sasl_authenticated
defer_unauth_destination
myhostname = lists.domain.org
mydestination = $myhostname, localhost.localdomain, localhost, $mydomain,
lists.domain.org
Any help is appreciated.
--
Samir Faci
On Sat, May 2, 2020 at 1:40 PM Andrew Hodgson <andrew(a)hodgson.io> wrote:
> Mark Sapiro <mark(a)msapiro.net> wrote:
> >On 5/2/20 12:51 AM, Samir Faci wrote:
> >> A few questions about an Ubuntu install.
> >>
> >> i'm getting this behavior:
>
> >> AttributeError: module 'time' has no attribute 'clock'
>
>
> >> I'm on python 3.8.2
>
>
> >It time.clock() went away in Python 3.8. Mailman versions older than
> >3.3.0 are not compatible with Python 3.8. You need to upgrade Mailman
> core.
>
> I think this is a bug in Ubuntu 20.04.
>
> Python3 package is:
> Python3 3.8.2-0ubuntu2
> https://packages.ubuntu.com/search?suite=focal&keywords=python3
> Mailman3 is: 3.2.2-1
> https://packages.ubuntu.com/search?suite=focal&keywords=mailman3
>
> Andrew.
> _______________________________________________
> Mailman-users mailing list -- mailman-users(a)mailman3.org
> To unsubscribe send an email to mailman-users-leave(a)mailman3.org
> https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/
>
--
Thank you
Samir Faci
https://keybase.io/csgeek
5 years, 1 month

[MM3-users] Re: mailman3 not working for mailman21 lists
by Stephen J. Turnbull
blup(a)fortytwo.ch writes:
> First I did create the list with the old name and imported the old
> configs with mailman import21. As the list did not work then, I
> deleted it and created it again (with the same manual configuration
> as for the new list that's working).
OK. So as far as you know the configurations of list1 and list2 on
Mailman 3 are identical, at least in the case where you have deleted
list1 and recreated by hand.
> I don't have a qfiles directory.
Try queue/, especially look for the out[going], pipeline, and shunt
subdirectories.
> > Is the 'outgoing' qrunner still running? (ps ax | grep outgoing)
>
> no
Sorry, I got that wrong. Mark recommends this:
ps -fwwA|grep runner=|sed s/.*runner=//
and gave this as sample output:
archive:0:1
bounces:0:1
command:0:1
in:0:1
lmtp:0:1
nntp:0:1
out:0:1
pipeline:0:1
rest:0:1
retry:0:1
task:0:1
virgin:0:1
digest:0:1
rest:0:1
rest:0:1
so it looks like the process name of the runner is "out", not
"outgoing". Besides checking for the "out" runner, also check for
"pipeline", which has been known to fail in the past.
> But once more: list1 was working fine as long as mailman21 was used
> and stopped working when switching to mailman3. I don't expect spam
> filters that worked with mailman21 to stop working with mailman3.
Mailman 3 is a complete rewrite, essentially no Mailman 2 code was
left untouched because of the pervasiveness of the change of the
fundamental string type str from encoded bytes to abstract characters.
I don't expect behavior to change, but I certainly am not going to
rule anything out when trying to diagnose problems based on so little
information.
> I have more or less no Python knowledge (i.e. I can read and
> understand Python but can't write it). Could you please give me
> detailed command by command instructions. Thanks.
I'll take a look at it tomorrow, but I can't promise results until the
weekend if I can't write a script in 30 minutes. Normally Mark Sapiro
would handle this kind of thing, but he's offline for a couple weeks
so you've got me. My knowledge is mostly on the email protocols side
of things (Internet message format, authentication protocols), not the
internal processing. I'll do what I can, but if I can't do it real
quick it's probably going to take me several hours, which I'm not
going to have until the weekend.
Steve
2 years, 10 months

[MM3-users] Re: Mailman issues after re-boot
by Odhiambo Washington
On Sat, Sep 16, 2023 at 5:49 PM Paul Rubin <paulrubin37(a)gmail.com> wrote:
> *<< I sent this to the mailman3 issues on gitlab and Mark replied but asked
> me to move to this list, so I copied everything and inserted responses. I
> hope this makes sense and someone can help me.>>*
>
> After a lengthy power failure I had to reboot a machine that has been
> running for several years. the WEB-UI does not seem to be able to see
> mailman-core. I have looked for log entries that might explain what the
> issue is and I am stumped to even find logs that will update when I get an
> error on the browser. Mailman is definitely running, postgres is running
> and mailman web is running. if I go to the lists page I see lists, if I try
> to access a specific list I get Server error: An error occurred while
> processing your request.
>
> I looked in /var/logs/mailman /opt/mailman/web/mailmanweb
>
> All I can find is:
>
> django.urls.exceptions.NoReverseMatch: Reverse for
> 'list_unsubscription_requests' not found.
> 'list_unsubscription_requests' is not a valid view function or pattern
> name.16688 ERROR 2023-09-12 13:56:58,430 1760 django.request Internal
> Server Error: /mailman3/lists/goodstein.goodstein.org/ File
> "/opt/mailman/venv/lib64/python3.8/site-packages/haystack/admin.py",
> line 8, in <module> from django.utils.translation import
> ungettextImportError: cannot import name 'ungettext' from
> 'django.utils.translation'
>
> (/opt/mailman/venv/lib64/python3.8/site-packages/django/utils/translation/__init__.py)
>
> Also I have to run mailman from "mailman start" because the systemctl
> returns this:
>
> ● mailman3.service - GNU Mailing List Manager Loaded: loaded
> (/etc/systemd/system/mailman3.service; enabled; vendor preset:
> disabled) Active: failed (Result: exit-code) since Tue 2023-09-12
> 10:06:31 EDT; 13s ago Process: 31159
> ExecStart=/opt/mailman/venv/bin/mailman start (code=exited,
> status=1/FAILURE) CPU: 806msSep 12 10:06:31 mail
> mailman[31159]: Error in atexit._run_exitfuncs:Sep 12 10:06:31 mail
> mailman[31159]: Traceback (most recent call last):Sep 12 10:06:31 mail
> mailman[31159]: File "/usr/lib64/python3.8/logging/__init__.py",
> line 2126, in shutdownSep 12 10:06:31 mail mailman[31159]:
> h.flush()Sep 12 10:06:31 mail mailman[31159]: File
> "/opt/mailman/venv/lib64/python3.8/site-packages/mailman/core/logging.py",
> line 67, in flushSep 12 10:06:31 mail mailman[31159]: if
> self._stream:Sep 12 10:06:31 mail mailman[31159]: AttributeError:
> 'ReopenableFileHandler' object has no attribute '_stream'Sep 12
> 10:06:31 mail systemd[1]: mailman3.service: Control process exited,
> code=exited, status=1/FAILURESep 12 10:06:31 mail systemd[1]:
> mailman3.service: Failed with result 'exit-code'.Sep 12 10:06:31 mail
> systemd[1]: Failed to start GNU Mailing List Manager.
>
> Please tell me where to start looking or adjusting.
>
>
> Reply from Mark Sapiro,* Edited to include responses:*
>
> Mark Sapiro <https://gitlab.com/msapiro>@msapiro
> <https://gitlab.com/msapiro>· 1 day ago
> <https://gitlab.com/mailman/mailman-web/-/issues/23#note_1557601916>
> Owner
> Add reaction
> More actions
>
> The mailman-users(a)mailman3.org list is probably a more appropriate place
> for issues like this.
>
> django.urls.exceptions.NoReverseMatch: Reverse for
> 'list_unsubscription_requests' not found. 'list_unsubscription_requests' is
> not a valid view function or pattern name. 16688 ERROR 2023-09-12
> 13:56:58,430 1760 django.request Internal Server Error: /mailman3/lists/
> goodstein.goodstein.org/
>
> /opt/mailman/venv/lib64/python3.8/site-packages/postorius/urls.py should
> contain
>
> re_path( r'^unsubscription_requests$',
> list_views.list_unsubscription_requests,
> name='list_unsubscription_requests', ),
>
> Y
>
> *Yes this exists*
>
> and /opt/mailman/venv/lib64/python3.8/site-packages/postorius/views/list.py
> should define list_unsubscription_requests.
>
> *Yes there is a method by this name defined*
>
> File "/opt/mailman/venv/lib64/python3.8/site-packages/haystack/admin.py",
> line 8, in from django.utils.translation import ungettext ImportError:
> cannot import name 'ungettext' from 'django.utils.translation'
> (/opt/mailman/venv/lib64/python3.8/site-packages/django/utils/translation/
> *init*.py)
>
> See
>
> https://docs.djangoproject.com/en/4.2/internals/deprecation/#deprecation-re…
> -
> ungettext() is removed from django>=4.0
>
> Sep 12 10:06:31 mail mailman[31159]: AttributeError:
> 'ReopenableFileHandler' object has no attribute '_stream'
>
> I don't understand this one offhand, but what is the content of
> /etc/systemd/system/mailman3.service, in particular the settings for User,
> Group and ExecStart?
>
> *The service looks right:*
>
> 1 [Unit]
> 2 Description=GNU Mailing List Manager
> 3 After=syslog.target network.target postgresql.service
> 4
> 5 [Service]
> 6 Type=forking
> 7 PIDFile=/opt/mailman/mm/var/master.pid
> 8 User=mailman
> 9 Group=mailman
> 10 ExecStart=/opt/mailman/venv/bin/mailman start
> 11 ExecReload=/opt/mailman/venv/bin/mailman restart
> 12 ExecStop=/opt/mailman/venv/bin/mailman stop
> 13
> 14 [Install]
> 15 WantedBy=multi-user.target
>
> *It seems I may have two versions of the mailman script:*
>
> mail:/opt/mailman # which mailman
> /usr/bin/mailman
> mail:/opt/mailman # ls -al /usr/bin/mailman
> -rwxr-xr-x 1 root root 382 May 10 2021 /usr/bin/mailman
> mail:/opt/mailman # ls -al /opt/mailman/venv/bin/mailman
> -rwxr-xr-x 1 mailman mailman 231 Sep 12 10:02 /opt/mailman/venv/bin/mailman
>
> Somehow, your installation is corrupted. I don't know how
>
> *I need to know what to remove, how to correctly update, etc., That said
> the two scripts appear to be very similar:*
>
> mail:/opt/mailman # head /usr/bin/mailman
>
> #!/usr/bin/python3
> # EASY-INSTALL-ENTRY-SCRIPT: 'mailman==3.3.4','console_scripts','mailman'
> __requires__ = 'mailman==3.3.4'
> import re
> import sys
> from pkg_resources import load_entry_point
>
> if __name__ == '__main__':
> sys.argv[0] = re.sub(r'(-script\.pyw?|\.exe)?$', '', sys.argv[0])
> sys.exit(
>
>
> mail:/opt/mailman # head /opt/mailman/venv/bin/mailman
> #!/opt/mailman/venv/bin/python3
> # -*- coding: utf-8 -*-
> import re
> import sys
> from mailman.bin.mailman import main
> if __name__ == '__main__':
> sys.argv[0] = re.sub(r'(-script\.pyw|\.exe)?$', '', sys.argv[0])
> sys.exit(main())
> mail:/opt/mailman #
>
> *Given the two years since the last reboot I also tried following *
> https://docs.mailman3.org/en/latest/upgrade-guide.html *to make sure I was
> running the latest*
>
> pip install -U mailman postorius django-mailman3 hyperkitty mailman-web
>
Why don't you try and do a fresh virtualenv install and move your configs
into it?
1. cd /opt
2. mv mailman _mailman.BAK
3. Create a backup of the database.
Then follow this:
https://docs.mailman3.org/en/latest/install/virtualenv.html#virtualenv-inst…,
but do not create the database as it already exists.
You also do not need to run any database migrations, so you can actually
skip those
You just need to ensure that `mailman info` says that its configuration
files are in /etc/mailman3/
Create the necessary directories as per the above installation instructions.
--
Best regards,
Odhiambo WASHINGTON,
Nairobi,KE
+254 7 3200 0004/+254 7 2274 3223
"Oh, the cruft.", egrep -v '^$|^.*#' ¯\_(ツ)_/¯ :-)
[How to ask smart questions:
http://www.catb.org/~esr/faqs/smart-questions.html]
1 year, 9 months

[MM3-users] Lessons learned and a couple little gotcha for newbies
by William Oliver
I just finished, with great help from Mark Sapiro on the list, a new
installation of mailman3.
I used the instructions at
https://docs.mailman3.org/projects/mailman/en/latest/src/mailman/docs/insta…
and
https://docs.mailman3.org/en/latest/install/virtualenv.html
There were a couple of gotchas that I didn't see well documented.
1) I got the error
django.template.library.InvalidTemplateLibrary: Invalid template
library specified. ImportError raised when trying to load
'hyperkitty.templatetags.decorate': cannot import name 'escape_html'
from 'mistune.scanner' (/opt/mailman/venv/lib/python3.9/site-
packages/mistune/scanner.py)
when I ran 'mailman-web migrate'
The fix was trivial: I just added the lines:
from mistune.util import escape_html
from mistune.util import escape_url
to
/opt/mailman/venv/lib/python3.9/site-packages/mistune/scanner.py
It's not hard to search for those definitions, but if someone doesn't
know a smattering of python, it might not be obvious.
2) Similarly, migrate (using postgres) also gave the error:
File "/opt/mailman/venv/lib/python3.9/site-
packages/django/db/backends/postgresql/utils.py", line 6, in
utc_tzinfo_factory
raise AssertionError("database connection isn't set to UTC")
I was able to find a discusson of this one at
https://stackoverflow.com/questions/68024060/assertionerror-database-connec…
which had me downgrade to an older version of psycopg2-binary:
pip install psycopg2-binary==2.8.6
There might be a different fix, but this worked.
3) When I ran the test "uwsgi --ini /etc/mailman3/uwsgi.ini" I got the
error:
ModuleNotFoundError: No module named 'settings'
This was also trivially fixed by adding the path:
export PYTHONPATH=$PYTHONPATH:/etc/mailman3
in /opt/mailman/.bashrc
4) Sometimes when I rebooted the machine, when I ran 'systemctl start
mailman3' I'd get the error that mailman wouldn't start because the
lock was stll there. I never could figure out where the lock was, so I
worked around it by replacing
ExecStart=/opt/mailman/venv/bin/mailman start
with
ExecStart=/opt/mailman/venv/bin/mailman start --force
in /etc/systemd/system/mailman3.service
I'm sure there's something bad about doing that, but it works for me,
so far.
5) I had a problem with mail to outside people not being delivered
while mail to the local host was delivered. It turned out that this was
because in my mailman.cfg I had "smtp_host:my.listserver.tld when it
should have been localhost. The error was "relay access denied." To
fix this, I had to add my.listserver.tld to "mynetworks" in
/etc/postfix/main.cf, ie change:
mynetworks = 127.0.0.0/8 10.0.0.0/24
to
mynetworks = 127.0.0.0/8 10.0.0.0/24 111.222.333.444 <--- my ip address
However, Mark Sapiro (a God) told me this was because I had changed a
line in the [mta] section of mailman.cfg. I had changed
smtp_host: localhost
to
smtp_host: mydomain.tld
Here's the thing. The reason I did this was because the instructions at
https://docs.mailman3.org/en/latest/config-core.html
give this as their model:
[mta]
incoming: mailman.mta.postfix.LMTP
outgoing: mailman.mta.deliver.deliver
lmtp_host: mail.example.com
lmtp_port: 8024
smtp_host: mail.example.com <---- not localhost
smtp_port: 25
The instructions are good, but there are a few places where one size
does not fit all, I guess.
6) A second error in delivery to outside addresses resulted in an
"Access denied" error. A search on the internet revealed that this had
to do with (for me) smtpd_recipient_restrictions in postfix. See, for
instance:
https://know.mailsbestfriend.com/postfix_error_relay_access_denied_noqueue_…
Changing this fixed things.
I'm not sure, but I think this shows up mostly with installations that
include dovecot.
7) If you are using virtual domains in postfix, you need to use the
"unusual postfix configuration" in
https://docs.mailman3.org/projects/mailman/en/latest/src/mailman/docs/mta.h…
virtual_alias_maps =
hash:/path-to-mailman/var/data/postfix_vmap
8) You need to manually set the local virtual host for mailman3.
Somehow, I got the impression from the installation instructions that
this was done automagically to the default x.mydomain.tld if your
domain is mydomain.tld. It doesn't.
9) Follow the instructions verbatim, and follow them in the order
provided. I installed postfix and nginx out of order, and it did OK,
but once you get into the python virtual environment, it is easy to
miss something if you don't do it in order.
10) Jot down lots of notes. This is one of the more complicated
installations I've done, mostly because it involved configuring a
zillion packages to talk to each other: Postfix, nginx, postorius,
hyperkitty, django, and others (I'd never heard of "whoosh" or "sass"
for instance). All of these can be unforgiving with configuration
errors.
The default installation instructions assumed a number of packages I'd
never used. I'm an apache/dovecot/mysql kind of person, and I had to
switch to nginx/postgres to use the instructions as the written
defaults. I'm sure I could have used apache and mysql, but it would
mean trying to figure out what didn't work without following the
installations verbatim. I'd never even heard of postorius, hyperkitty,
or django.
So, it was easy to get confused a bit. Taking notes of changes I made
was important in being able to back out of disastrous choices. Plus,
once I'd installed it on one machine, I sat down and installed it on
another machine, and it was very useful to have written down how I
fixed an issue when it came up again -- and I didn't remember exactly
what I had done.
11) Make multiple sequential backups of configuration files. I went
down a couple of paths I shouldn't have gone down. For instance, with
the vmap issue, I got it in my head that it was a postfix configuration
issue, not a mailman issue. So I kept changing things in postfix.
Once I was told that it was in *mailman* I had to set the virtual host,
I needed to back out of about 8 tweaks I'd made to main.cf in
/etc/postfix. If I hadn't been making main.cf.backup.01,
main.cf.backup.02, etc. I would have had to spend another few hours
trying to remember what inappropriate changes I had made.
This is particularly true for me because I am not a great typist, and
when I try to retype something to back out, there's a reasonable chance
I'll mistype something and it still won't work. With these backups, I
don't have both manually back out of things *and* proof my typing again
and again. It's a lot easier to delete backups once things are working
than to try to remember what you did late at night after a couple of
bourbons.
12) Choose one set of installation instructions and follow it. Don't
try to mix instructions from different tutorials unless you really know
what you are doing. I didn't. For instance, there's a different set
of mailman3 installation instructions at:
https://wiki.list.org/DOC/Howto_Install_Mailman3_On_Debian10
It does things a little differently. It's useful to look at that when
you are debugging why something's not working, but you can get into
some trouble trying to do both installations at the same time -- which
I found myself doing when something wasn't working. It didn't help.
billo
3 years, 6 months

[MM3-users] Re: how to administrate mailman3 in CLI ?
by testeur
Sorry. I didn't see in the good place.
when i see parameters here :
https://URL/mailman3/postorius/accounts/per-subscription-preferences/
the options or the specific language chosen (not for the ui) for the
list is finally changing when i use the code used before...
i should use shell with mailman user. ok i note it.
I ve seen this link about python script to manage mailman3 by shell :
https://fog.ccsf.edu/~msapiro/scripts/ (thx you)
Regards,
On 23/09/2023 17:33, Mark Sapiro wrote:
> On 9/23/23 07:40, testeur via Mailman-users wrote:
>>
>> |# mailman shell -l testlist(a)domain.tld |
>
> It looks like you are running `mailman shell` as `root`. You should
> always run mailman commands including starting mailman as the Mailman
> user, never as root. Running thing as root can create things that
> later can't be read by the mailman user.
>
>> ||>>> from mailman.interfaces.action import Action >>> for mbr in
>> m.members.members: mbr.moderation_action = Action.defer |||commit()|
>>
>> |||>>> from mailman.interfaces.action import Action |||||||>>>
>> english = getUtility(ILanguageManager).get('en')| >>> for mbr in
>> m.members.members: || mbr.preferences.acknowledge_posts = False
>> mbr.preferences.delivery_mode = DeliveryMode.regular
>> mbr.preferences.delivery_status = DeliveryStatus.enabled
>> mbr.preferences.hide_address = False
>> mbr.preferences.preferred_language = english
>> mbr.preferences.receive_list_copy = False
>> mbr.preferences.receive_own_postings = True|commit()||
>
>
> I'm not sure what the above actually says. The interaction should look
> like
> ```
> >>> from mailman.interfaces.action import Action
> >>> english = getUtility(ILanguageManager).get('en')
> >>> for mbr in m.members.members:
> ... mbr.preferences.acknowledge_posts = False
> ... mbr.preferences.delivery_mode = DeliveryMode.regular
> ... mbr.preferences.delivery_status = DeliveryStatus.enabled
> ... mbr.preferences.hide_address = False
> ... mbr.preferences.preferred_language = english
> ... mbr.preferences.receive_list_copy = False
> ... mbr.preferences.receive_own_postings = True
> ...
> >>> commit()
> ```
> Actually, importing Action is not necessary as it is among the things
> defined by default in `mailman shell` in interactive mode.
>
>> Before the shell command, the web interface was with an other
>> language (i tested with italian one) and other options preferences,
>> but after the shell command, after a web interface refresh, it
>> doesn't change.
>
>
> The above shell interaction sets the preferred_language for all list
> members to english. This has nothing to do with the language for the
> web UI. This is set by Django. See
> <https://docs.djangoproject.com/en/4.2/topics/i18n/translation/#how-django-d…>.
>
>
1 year, 9 months

[MM3-users] Re: A little stuck with installation of MM3 - ModuleNotFoundError: No module named 'flufl.lock'
by Odhiambo Washington
On Thu, 30 Jul 2020 at 20:45, Mark Sapiro <mark(a)msapiro.net> wrote:
> On 7/30/20 1:53 AM, Odhiambo Washington wrote:
> >
> > os.environ.setdefault("DJANGO_SETTINGS_MODULE", "settings")
>
>
> Try changing this one line in wsgi.py to
>
> os.environ["DJANGO_SETTINGS_MODULE"] = "settings"
>
That option did not work.
>
> If that doesn't work, try adding these two lines following the line
>
> import os
>
>
> import sys
> sys.path.insert(0, '/opt/mailman/mm')
>
This works - I mean changes the error message to
[Thu Jul 30 18:11:50.269667 2020] [wsgi:error] [pid 7627] [remote
197.232.81.246:63962]
/opt/mailman/mm/venv/lib/python3.7/site-packages/readme_renderer-26.0-py3.7.egg/readme_renderer/markdown.py:38:
UserWarning: Markdown renderers are not available. Install
'readme_renderer[md]' to enable Markdown rendering.
[Thu Jul 30 18:11:50.269700 2020] [wsgi:error] [pid 7627] [remote
197.232.81.246:63962] warnings.warn(_EXTRA_WARNING)
[Thu Jul 30 21:11:50.573233 2020] [authz_core:error] [pid 10846] [client
197.232.81.246:63962] AH01630: client denied by server configuration:
/var/spool/mailman-web, referer:
http://mm3-lists.my.server/mm3/mailman3/lists/
There is NO /var/spool/mailman-web anywhere. It has not been created.
You mentioned that it should be created automatically, IIRC.
root@gw:*/opt/mailman/mm* # ls -al
total 116
drwxr-xr-x 8 mailman3 wheel 512 Jul 29 10:06 .
drwxr-xr-x 7 mailman3 wheel 512 Jul 28 14:17 ..
drwxr-xr-x 8 mailman3 wheel 512 Jul 25 22:16 .sass-cache
-rw-r--r-- 1 mailman3 wheel 0 Jul 29 10:06 __init__.py
drwxr-xr-x 2 mailman3 wheel 512 Jul 30 21:12 __pycache__
-rw-r--r-- 1 mailman3 wheel 2372 Jul 28 13:16 _settings_local.py
drwxr-xr-x 2 mailman3 wheel 512 Jul 25 14:42 bin
-rw-r--r-- 1 mailman3 wheel 248 Jul 25 14:37 gunicorn.conf
-rw-r--r-- 1 mailman3 wheel 266 Jul 26 15:34 gunicorn.conf.py
-rw-r--r-- 1 mailman3 wheel 0 Jul 28 12:19 init.py
lrwxr-xr-x 1 mailman3 wheel 24 Jul 25 14:39 logs ->
/opt/mailman/mm/var/logs
-rw-r--r-- 1 mailman3 wheel 445 Jul 28 11:37 mailman-hyperkitty.cfg
-rw-r--r-- 1 mailman3 wheel 1291 Jul 26 17:12 mailman.cfg
-rw-r--r-- 1 mailman3 wheel 15516 Jul 27 16:32 settings.py
-rw-r--r-- 1 mailman3 wheel 16069 Jul 28 13:15 settings_local.py
-rw-r----- 1 mailman3 wheel 5914 Jul 27 17:35 settings_local.py.2
-rw-r--r-- 1 mailman3 wheel 15831 Jul 27 16:21 settings_local.py.BAK
drwxr-xr-x 9 mailman3 wheel 512 Jul 25 22:16 static
-rw-r--r-- 1 mailman3 wheel 1395 Jul 25 14:35 urls.py
drwxr-xr-x 12 mailman3 wheel 512 Jul 30 21:12 var
drwxr-xr-x 5 mailman3 wheel 512 Jul 26 17:11 venv
-rw-r--r-- 1 mailman3 wheel 1271 Jul 30 21:03 wsgi.py
--
Best regards,
Odhiambo WASHINGTON,
Nairobi,KE
+254 7 3200 0004/+254 7 2274 3223
"Oh, the cruft.", grep ^[^#] :-)
4 years, 11 months

[MM3-users] Re: very few moderation capabilities for moderators
by Guillermo Hernandez (Oldno7)
On 16/9/21 16:40, Mark Sapiro wrote:
> On 9/16/21 2:39 AM, Guillermo Hernandez (Oldno7) via Mailman-users wrote:
>> Hi all:
>>
>> I need to provide the list moderators a way to change the moderation
>> flag for users from whichever it is (normally "list default
>> processing") to "hold for moderation" and viceversa (to "list
>> default" or to "accept")
>>
>> I understand that it could be done via console script (That's the way
>> I did on mailman2: I made two commands using "withlist", one to hold,
>> moderar.py, and other one to accept, desmoderar.py. I show you below)
>
>
> Are you asking what the equivalent MM 3 scripts would be?
>
More or less: I'm asking for a general direction here. I think I cannot
use tthe "withlist" method as before, inside a python script, and I'm
not sure how to do it. I've been reviewing all the command docs that
I've found, but I have no clear way. I need a shell or a python script
that I can pass the list and the mail address to put on hold/hold (that
way the moderators can log in a special account thhat asks for the
address to hold/unhold). I did it in mailman2 whith the bin/withlist
command, but now whithlist seems to be an alias for shell and is
interactive.Thats not my goal)
>
>> But I think I'm not the only one that could use as an improvement a
>> way to do this on postorius/web.
>
>
> Postorius allows a list owner or site admin to set Moderation for list
> members and non members at e.g.
> https://www.example.com/mailman3/lists/list.example.com/members/(non)member/.
Yes, I know that. But the owner cannot be 24/7 attending the lists (as
we all know), and could need a help hand from moderators. Not just from
accepting mails on hold, but to put on hold a member (and be capable of
reversing it) when the netiquete dissapears completely and some thread
becomes a flame and all goes south. I'ts the admin capability I miss
the most for moderators in mailman.
> Currently, a list moderator who is not an owner cannot do this, but a
> moderator can set Moderation for the sender of a held post when
> handling the post.
But I'm talking about a moderator can put a member mails in hold when
it is marked to accept. To prevent putting more gas in the fire.
>
>
3 years, 9 months

[MM3-users] Re: Postorius confirmation mails shown in uwsgi-error.log but not sent
by Ralph Seichter
* Mark Sapiro:
> What is the complete log message from uwsgi-error.log?
I'll attach a typical log file to this message. It shows startup
messages followed by a recorded confirmation email. User name and
domain are obfuscated, but other than that the log is unchanged.
-Ralph
*** Starting uWSGI 2.0.18 (64bit) on [Sat Mar 28 20:55:36 2020] ***
compiled with version: 9.3.0 on 26 March 2020 13:58:28
os: Linux-5.5.13-gentoo #1 SMP Thu Mar 26 10:24:38 CET 2020
nodename: wedjat
machine: x86_64
clock source: unix
pcre jit disabled
detected number of CPU cores: 8
current working directory: /var/lib/mailman
detected binary path: /var/lib/mailman/venv/bin/uwsgi
chdir() to /var/lib/mailman/suite/
your processes number limit is 256427
your memory page size is 4096 bytes
detected max file descriptor number: 1024
lock engine: pthread robust mutexes
thunder lock: disabled (you can enable it with --thunder-lock)
uwsgi socket 0 bound to TCP address 127.0.0.1:8002 fd 8
Python version: 3.8.2 (default, Feb 26 2020, 08:14:41) [GCC 9.2.0]
Python main interpreter initialized at 0x56443febc210
python threads support enabled
your server socket listen backlog is limited to 100 connections
your mercy for graceful operations on workers is 60 seconds
mapped 166752 bytes (162 KB) for 2 cores
*** Operational MODE: threaded ***
WSGI app 0 (mountpoint='') ready in 1 seconds on interpreter 0x56443febc210 pid: 21912 (default app)
*** uWSGI is running in multiple interpreter mode ***
spawned uWSGI master process (pid: 21912)
spawned uWSGI worker 1 (pid: 21916, cores: 2)
19:55:38 [Q] INFO Q Cluster pizza-illinois-golf-magnesium starting.
19:55:38 [Q] INFO Process-1:1 ready for work at 21921
19:55:38 [Q] INFO Process-1:2 ready for work at 21922
19:55:38 [Q] INFO Process-1:3 ready for work at 21923
19:55:38 [Q] INFO Process-1:4 ready for work at 21924
19:55:38 [Q] INFO Process-1:5 ready for work at 21925
19:55:38 [Q] INFO Process-1:6 ready for work at 21926
19:55:38 [Q] INFO Process-1:7 ready for work at 21927
19:55:38 [Q] INFO Process-1:8 ready for work at 21928
19:55:38 [Q] INFO Process-1:9 monitoring at 21929
19:55:38 [Q] INFO Process-1 guarding cluster pizza-illinois-golf-magnesium
19:55:38 [Q] INFO Process-1:10 pushing tasks at 21930
19:55:38 [Q] INFO Q Cluster pizza-illinois-golf-magnesium running.
Content-Type: text/plain; charset="utf-8"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Subject: [lists.domain.tld] Please Confirm Your E-mail Address
From: postmaster(a)domain.tld
To: OBFUSCATED(a)gmail.com
Date: Sat, 28 Mar 2020 20:08:15 -0000
Message-ID: <158542609570.21916.15168402908994348907(a)wedjat.domain.tld>
Hello from lists.domain.tld!
You're receiving this e-mail because user OBFUSCATED has given yours as an e-mail address to connect their account.
To confirm this is correct, go to https://lists.domain.tld/accounts/confirm-email/Mg:1jIHkd:x8NSjzCkP5ifX6V39…
Thank you from lists.domain.tld!
lists.domain.tld
-------------------------------------------------------------------------------
5 years, 3 months

[MM3-users] Re: mailman-core installation on debian stretch/maria-db
by Wolfgang Bock
Hi Mark,
thanks for your reply.
In my debian apt-get install the "mysql+pymysq" sentence was now
automaticly set.
My Debian dbconfig-mysql dependency refers to maria-db.
I had some problem of creating the database due to right-problems with
dbconfig. So I created the database manually and set permissions to the
database-user manually.
The results were shown yesterday.
Now I am stopping all efforts on fiddeling with mailman3, re-setup my
server in order to get rid of all that python stuff and will use mailman
2.1 which runs without problems and does all things I need. A
sql-membermanagement would be useful, but in this version not available.
And wait for an official mailman upgrade within the debian stretch
stable ...
Thank you for your efforts.
Regards
Wolfgang
Am 12.03.2018 um 02:24 schrieb Mark Sapiro:
> On 03/11/2018 03:11 PM, Wolfgang Bock wrote:
>
>> -> After I set a symlink to /sbin/master another errormessage occurs
>>>> 2. connection to maria-db
>>>> In debian stretch maria-db is running. In my mailman.cfg I set:
>>>> [database]
>>>> class: mailman.database.mysql.MySQLDatabase
>>>> url:
>>>> mysql+pmysql://#username#:#user-pawo#@localhost/#databasename#?charset=utf8&use_unicode=1
>>>>
>>> should that be mysql+pymysql ?
>> -> Yes, according to:
>> http://mailman.readthedocs.io/en/latest/src/mailman/docs/database.html
>> -> Not right??
>
> My point is you have 'mysql+pmysql' and you should have 'mysql+pymysql'.
> You are missing the first 'y' in 'pymysql'.
>
>
>> After that I decided to delete mailman via pip and took a new approach
>> via debians apt-get ... mailman 3
>>
>> So far so good, now new errormessage:
>>
>> Traceback (most recent call last):
> ...
>> AttributeError: module 'mailman.database.mysql' has no attribute
>> 'MYSQLDatabase'
>
> Did you install the Debian dbconfig-mysql dependency? I don't know how
> installation of mailman3-core determines which if any of the database
> dependencies, but you need that for sure to support MySQL/MariaDB.
>
>
>> Another question is, where can I find the sql-command within the
>> database mailman3 like CREATE TABLE x and TABLE y as I created a
>> database mailman3 which is empty??
>
> The database may be empty because of the above error and the fact you
> haven't yet done anything.
>
> All the database access is via SQLAlchemy and models defined in
> Mailman's mailman/models/ directory. See
> <http://mailman.readthedocs.io/en/latest/src/mailman/model/docs/model.html>.
>
7 years, 3 months

[MM3-users] Re: Weird startup problem after upgrade
by Odhiambo Washington
On Fri, Dec 2, 2022 at 8:58 PM Mark Sapiro <mark(a)msapiro.net> wrote:
> On 12/2/22 08:21, Odhiambo Washington wrote:
> > I am facing an odd situation in which MM3 doesn't start successfully on
> > reboot, but I can start it manually.
> > This is a venv install.
> > This started after I did an upgrade (pip install --upgrade mailman
> > postorius hyperkitty mailman-hyperkitty) followed by the requisite
> > collectstatic|compress|compilemessages|migrate
> > post-update commands.
>
>
> Was the venv activated when you ran pip?
>
Yes.
>
> You should also include django-mailman3 and mailmanclient in the
> packages to be upgraded although they are dependencies and "should"
> upgrade anyway.
>
I did not include them in the list of packages to be upgraded because I did
not explicitly install them when I installed my server.
In BC's HOWTO <https://wiki.list.org/DOC/Howto_Install_Mailman3_On_Debian10>
which
is what my MM3 server is based, they were never part of the modules (app?)
installed explicitly.
> Also, at least one person has noted that --force-reinstall was required
> to get all dependencies upgraded
> <
> https://lists.mailman3.org/archives/list/mailman-users@mailman3.org/message…
> >
>
I can try this as well and report back.
> > Secondly, it appears that the upgrade did NOT change the versions for the
> > upgraded components - postorius=1.3.6, hyperkitty=1.3.5,
> > Mailman Core Version=3.3.5. I was expecting the version to all bump up to
> > the latest.
>
>
> What does `pip freeze` in the venv show for versions?
>
Here is the listing: https://pastebin.ubuntu.com/p/tMGDxjKwJ8/
>
> > Thanks in advance for any insights into what could be causing this.
>
>
> How do you start it manually? `mailman start` or `systemctl start
> mailman3`?
systemctl start mailman3
> What's the content of /etc/systemd/system/mailman3.service?
>
root@lists:/home/wash# cat /etc/systemd/system/mailman3.service
[Unit]
Description=GNU Mailing List Manager
After=syslog.target network.target mysql.service postgresql.service
[Service]
Type=forking
PIDFile=/opt/mailman/mm/var/master.pid
User=mailman
Group=mailman
ExecStart=/opt/mailman/mm/bin/mailman start
ExecReload=/opt/mailman/mm/bin/mailman restart
ExecStop=/opt/mailman/mm/bin/mailman stop
[Install]
WantedBy=multi-user.target
A special note that before I did this upgrade, the startup wasn't an issue.
I can actually go back to where I was, because I have complete backup of my
venv before the update, but it would be great to
figure out why things are the way they are now.
--
Best regards,
Odhiambo WASHINGTON,
Nairobi,KE
+254 7 3200 0004/+254 7 2274 3223
"Oh, the cruft.", egrep -v '^$|^.*#' ¯\_(ツ)_/¯ :-)
2 years, 6 months

[MM3-users] Re: multiple sites on a mailman3 server question
by David Newman
> On Dec 29, 2021, at 08:49, William Oliver <billo(a)billoblog.com> wrote:
>
> On Tue, 2021-12-28 at 18:23 -0800, David Newman wrote:
>>>
>>> [snip]
>>> I'm using nginx
>> I'd asked about this a few weeks ago for a MM3 host running Ngnix
>> with a
>> few virtual domains, one of which runs Roundcubemail as its default.
>>
>> Mark Sapiro suggested the following, and it seems to be working OK.
>> You'll need these lines in the Nginx config file for each virtual
>> host
>> you define.
>>
>> # begin mailman3 stuff
>>
>> location /static/ {
>> alias /opt/mailman/web/static/;
>> }
>>
> [snip]
>
>
>
> No joy. This just makes it kind of work as the mailman interface when
> it gets rewritten.
>
> My problem is that the url is getting referred to
> domainname/mailman3/lists even when I don't want it to.
That sounds like an nginx configuration problem, not a Mailman3 issue.
One assumption in the MM3 web setup docs is that MM3/Django/Postorius/Hyperkitty are the only web services running. If they’re not, and there are other services running, you’ll need to tell Nginx where they are.
The setup I provided is an excerpt and covers only how to point to MM3 in such a scenario. It does not cover how to point to something else as root at, say, www.domain.tld.
This is off-topic for a Mailman3 list, but maybe check your default files in the sites-available directory, and also anything they point to, paying particular attention to where / points and which root directory you’re using. Same thing with any other config files in that directory.
dn
> Adding these
> changes just (partially) loads the mailman3 interface when it gets
> rewritten.
>
> What I'm trying to figure out is where uwsgi yanks control from nginx
> and does the rewriting. Pulling that proxypass stuff out will stop
> mailman3 from coming up, and adding it allows mailman3 to show its
> interface, but the address gets referred regardless.
>
> Somehow I need to tell uwsgi to ignore www.domain.com *or* somehow tell
> nginx not to push it to port 8000. But I don't see where nginx is
> getting told to go to 8000 in the www.domain.com section.
>
> billo
>
>
>
>
>
>
> _______________________________________________
> Mailman-users mailing list -- mailman-users(a)mailman3.org
> To unsubscribe send an email to mailman-users-leave(a)mailman3.org
> https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/
3 years, 6 months

[MM3-users] Re: Newbie question 2: Rewriting issue for bounced emails
by William Oliver
On Sat, 2021-12-25 at 10:29 -0800, Mark Sapiro wrote:
>
>
> This is the issue.
>
> See
> https://docs.mailman3.org/projects/mailman/en/latest/src/mailman/docs/mta.h…
>
> for information on configuring Postfix with mailing lists in a
> virtual
> domain.
>
>
Thanks, at least that changed the error :-)
Clearly that was the problem, but it uncovered a new one -- the mailman
vmap doesn't seem to be created. In the installation docs, it says
about /opt/mailman/mm/data/postfix_vmap:
"If this is done and the configured MTA is Postfix, Mailman will
create an additional /path-to-mailman/var/data/postfix_vmap file with
mappings from the example.com addresses to the corresponding addresses
in the alias_domain and will use the alias_domain in the other files. "
But, alas, I get a "temporary lookup failure" which isn't all that
helpful. However, if I wander over to /var/logs/syslog, I see:
Dec 25 15:18:23 libertyfp postfix/smtpd[20248]: error: open database
/opt/mailman/mm/var/data/postfix_vmap.db: No such file or directory
Dec 25 15:18:23 libertyfp postfix/smtpd[20248]: connect from
localhost[::1]
Dec 25 15:18:23 libertyfp postfix/trivial-rewrite[20252]: error: open
database /opt/mailman/mm/var/data/postfix_vmap.db: No such file or
directory
Dec 25 15:18:23 libertyfp postfix/trivial-rewrite[20252]: warning:
hash:/opt/mailman/mm/var/data/postfix_vmap is unavailable. open
database /opt/mailman/mm/var/data/postfix_vmap.db: No such file or
directory
Dec 25 15:18:23 libertyfp postfix/trivial-rewrite[20252]: warning:
virtual_alias_domains: hash:/opt/mailman/mm/var/data/postfix_vmap:
table lookup problem
Dec 25 15:18:23 libertyfp postfix/trivial-rewrite[20252]: warning:
virtual_alias_domains lookup failure
Dec 25 15:18:23 libertyfp postfix/trivial-rewrite[20252]: warning:
hash:/opt/mailman/mm/var/data/postfix_vmap is unavailable. open
database /opt/mailman/mm/var/data/postfix_vmap.db: No such file or
directory
Dec 25 15:18:23 libertyfp postfix/trivial-rewrite[20252]: warning:
virtual_alias_domains: hash:/opt/mailman/mm/var/data/postfix_vmap:
table lookup problem
Dec 25 15:18:23 libertyfp postfix/trivial-rewrite[20252]: warning:
virtual_alias_domains lookup failure
Dec 25 15:18:23 libertyfp postfix/smtpd[20248]: NOQUEUE: reject: RCPT
from localhost[::1]: 451 4.3.0 <billo(a)billoblog.com>: Temporary lookup
failure; from=<mailman(a)libertyfp.org> to=<billo(a)billoblog.com>
proto=ESMTP helo=<mail.libertyfp.org>
Dec 25 15:18:23 libertyfp postfix/smtpd[20254]: error: open database
/opt/mailman/mm/var/data/postfix_vmap.db: No such file or directory
and on and on. This looks like a clue to me -- that mailman3 did not
automagically make postfix_vmap.db.
Is there a "make-the-freaking-virtual- map-database" command in
mailman3, or is this postfix thing? Should I just touch the thing and
create an empty file? I'm a little scared to... The error message
makes me think that it should be populated with something...
Sigh. That's enough for today. I'm off to eat Christmas turkey.
Thanks for all your help this morning.
billo
3 years, 6 months

[MM3-users] translating templates (was: Re: spanish localization)
by Guillermo Hernandez (Oldno7)
On 13/2/21 20:00, Mark Sapiro wrote:
> Also note that the translations on weblate only affect strings in the
> core code. The Mailman core templates are not currently translated in
> weblate and there are currently no Spanish language templates. One would
> need to create Spanish translations of all the templates in
> <https://gitlab.com/mailman/mailman/-/tree/master/src/mailman/templates/en>
> and submit a merge request to add them to a mailman/templates/es/ directory.
I downladed the templates and I'm beginning the translation process, but
I have a question. What language map has to be used? In my S.O. it's
ISO-8859-15 but I'm concerned it has to be UTF-8... Better ask before
having to do a remapping of the files after...
It comes to my attention that three files have 0 bytes.
-rw-r--r-- 1 Oldno7 wheel 382 14 feb. 00:22
domain:admin:notice:new-list.txt
-rw-r--r-- 1 Oldno7 wheel 886 15 feb. 11:28 help.txt
-rw-r--r-- 1 Oldno7 wheel 289 14 feb. 00:22
list:admin:action:post.txt
-rw-r--r-- 1 Oldno7 wheel 120 14 feb. 00:22
list:admin:action:subscribe.txt
-rw-r--r-- 1 Oldno7 wheel 122 14 feb. 00:22
list:admin:action:unsubscribe.txt
-rw-r--r-- 1 Oldno7 wheel 133 14 feb. 00:22
list:admin:notice:disable.txt
-rw-r--r-- 1 Oldno7 wheel 71 14 feb. 00:22
list:admin:notice:removal.txt
-rw-r--r-- 1 Oldno7 wheel 59 14 feb. 00:22
list:admin:notice:subscribe.txt
-rw-r--r-- 1 Oldno7 wheel 257 14 feb. 00:22
list:admin:notice:unrecognized.txt
-rw-r--r-- 1 Oldno7 wheel 45 14 feb. 00:22
list:admin:notice:unsubscribe.txt
-rw-r--r-- 1 Oldno7 wheel 0 14 feb. 00:22
list:member:digest:header.txt
-rw-r--r-- 1 Oldno7 wheel 337 14 feb. 00:22
list:member:digest:masthead.txt
-rw-r--r-- 1 Oldno7 wheel 154 14 feb. 00:22
list:member:generic:footer.txt
-rw-r--r-- 1 Oldno7 wheel 0 14 feb. 00:22
list:member:regular:header.txt
-rw-r--r-- 1 Oldno7 wheel 562 14 feb. 00:22
list:user:action:invite.txt
-rw-r--r-- 1 Oldno7 wheel 753 14 feb. 00:22
list:user:action:subscribe.txt
-rw-r--r-- 1 Oldno7 wheel 739 14 feb. 00:22
list:user:action:unsubscribe.txt
-rw-r--r-- 1 Oldno7 wheel 0 14 feb. 00:22
list:user:notice:goodbye.txt
-rw-r--r-- 1 Oldno7 wheel 281 14 feb. 00:22 list:user:notice:hold.txt
-rw-r--r-- 1 Oldno7 wheel 439 14 feb. 00:22
list:user:notice:no-more-today.txt
-rw-r--r-- 1 Oldno7 wheel 98 14 feb. 00:22 list:user:notice:post.txt
-rw-r--r-- 1 Oldno7 wheel 568 14 feb. 00:22
list:user:notice:probe.txt
-rw-r--r-- 1 Oldno7 wheel 273 14 feb. 00:22
list:user:notice:refuse.txt
-rw-r--r-- 1 Oldno7 wheel 151 14 feb. 00:22
list:user:notice:rejected.txt
-rw-r--r-- 1 Oldno7 wheel 353 14 feb. 00:22
list:user:notice:warning.txt
-rw-r--r-- 1 Oldno7 wheel 532 14 feb. 00:22
list:user:notice:welcome.txt
TIA.
4 years, 4 months

[MM3-users] Re: "Cannot connect to SMTP server localhost on port 25"
by Manos Pitsidianakis
Στις 2019-09-21 22:18, Mark Sapiro έγραψε:
> On 9/21/19 1:00 PM, Manos Pitsidianakis wrote:
>>
>> Can I use a debugger to see exactly what happens in the runner?
>
>
> You might be able to run the runner under pdb
> <https://docs.python.org/3.2/library/pdb.html>.
I think I found what's wrong:
/usr/local/lib/python3.5/dist-packages/mailman/core/runner.py(134)run()
-> filecnt = self._one_iteration()
/usr/local/lib/python3.5/dist-packages/mailman/core/runner.py(173)_one_iteration()
-> self._process_one_file(msg, msgdata)
/usr/local/lib/python3.5/dist-packages/mailman/core/runner.py(266)_process_one_file()
-> keepqueued = self._dispose(mlist, msg, msgdata)
/usr/local/lib/python3.5/dist-packages/mailman/runners/outgoing.py(95)_dispose()
-> self._func(mlist, msg, msgdata)
/usr/local/lib/python3.5/dist-packages/mailman/mta/deliver.py(86)deliver()
-> refused = agent.deliver(mlist, msg, msgdata)
> /usr/local/lib/python3.5/dist-packages/mailman/mta/base.py(163)deliver()
-> callback(mlist, message_copy, msgdata_copy)
/usr/local/lib/python3.5/dist-packages/mailman/mta/decorating.py(32)decorate()
-> decorator.process(mlist, msg, msgdata)
/usr/local/lib/python3.5/dist-packages/mailman/handlers/decorate.py(264)process()
-> process(mlist, msg, msgdata)
/usr/local/lib/python3.5/dist-packages/mailman/handlers/decorate.py(89)process()
-> footer = decorate('list:member:regular:footer', mlist, d)
/usr/local/lib/python3.5/dist-packages/mailman/handlers/decorate.py(226)decorate()
-> template = getUtility(ITemplateLoader).get(name, mlist, **extradict)
/usr/local/lib/python3.5/dist-packages/mailman/model/template.py(188)get()
-> name, lookup_context, **substitutions)
/usr/local/lib/python3.5/dist-packages/mailman/database/transaction.py(85)wrapper()
-> return function(args[0], config.db.store, *args[1:], **kws)
/usr/local/lib/python3.5/dist-packages/mailman/model/template.py(109)get()
-> contents = protocols.get(actual_uri, **auth)
/usr/local/lib/python3.5/dist-packages/mailman/utilities/protocols.py(38)get()
-> response = requests.get(url, timeout=REQUEST_TIMEOUT, **kws)
/usr/lib/python3/dist-packages/requests/api.py(70)get()
-> return request('get', url, params=params, **kwargs)
/usr/lib/python3/dist-packages/requests/api.py(56)request()
-> return session.request(method=method, url=url, **kwargs)
/usr/lib/python3/dist-packages/requests/sessions.py(488)request()
-> resp = self.send(prep, **send_kwargs)
/usr/lib/python3/dist-packages/requests/sessions.py(609)send()
-> r = adapter.send(request, **kwargs)
/usr/lib/python3/dist-packages/requests/adapters.py(487)send()
-> raise ConnectionError(e, request=request)
requests.exceptions.ConnectionError:
HTTPConnectionPool(host='localhost', port=8000): Max retries exceeded
with url:
/mailman3/api/templates/list/meli-announce.meli.delivery/list:member:regular:footer
(Caused by
NewConnectionError('<requests.packages.urllib3.connection.HTTPConnection
object at 0x7f4f0495a358>: Failed to establish a new connection: [Errno
111] Connection refused',))
mailman3 tries to get the template I've set via the mailman suite
interface but it assumes it is hosted locally:
'http://localhost:8000/mailman3/api/templates/list/meli-announce.meli.delive…'
In my setup, they are separate machines. I can't find any way to change
this in the configuration. Also, can't the same template be loaded from
the master's localhost:8001 api?
Haven't fiddled with python for some time, why is this exception catched
by "except socket.error"? Is it a subclass of
requests.exceptions.ConnectionError?
5 years, 9 months

[MM3-users] Re: hyperkitty won't list more than 5 posts and shows empty grey Activity Summary box
by Abhilash Raj
Hi,
On Wed, 9 Aug 2017 13:42:20 -0700
Mark Sapiro <mark(a)msapiro.net> wrote:
> On 08/09/2017 12:56 PM, cyp(a)trojina.si wrote:
> > Thanks for the quick and helpful reply. (However, please note that until now I was under the impression that there had been no response yet to my question, since my post appears to indicate having 0 comments at https://lists.mailman3.org/archives/list/mailman-users@mailman3.org/2017/8/)
>
>
> Yes, I see that. It was apparently an issue with caching. I recently
> enabled memcached on the server for django and apparently there was an
> issue with that. I just did what @abompard suggested at
> <https://gitlab.com/mailman/hyperkitty/issues/131#note_30244378> and
> that seems to have fixed it, at least for the moment.
>
>
> > Yes, the one-liner did indeed help the "More ..." problem. :)
> >
> > As for the bar graph, it's showing a bar now, probably correct. But I have not seen anything about django cronjobs in the MM3 documentation, haven't set any up, can't find any in our (Ubuntu 16.04) system and haven't done anything to fix this in-between (although I have restarted mailman-core and mailman-suite a few times). Could you point me in the right direction?
>
>
> This is what I have in Mailman's crontab on lists.mailman3.org
>
> > @hourly /opt/mailman/mailman-bundler/bin/mailman-web-django-admin runjobs hourly
> > @daily /opt/mailman/mailman-bundler/bin/mailman-web-django-admin runjobs daily
> > @weekly /opt/mailman/mailman-bundler/bin/mailman-web-django-admin runjobs weekly
> > @monthly /opt/mailman/mailman-bundler/bin/mailman-web-django-admin runjobs monthly
> > @yearly /opt/mailman/mailman-bundler/bin/mailman-web-django-admin runjobs yearly
> > 0,15,30,45 * * * * /opt/mailman/mailman-bundler/bin/mailman-web-django-admin runjobs quarter_hourly
> > * * * * * /opt/mailman/mailman-bundler/bin/mailman-web-django-admin runjobs minutely
> >
> > # Send periodic digests.
> > # I like 03:30 so they go overnight, but since we're 'global' and on UTC,
> > # maybe 07:30 is good.
> > 30 7 * * * /opt/mailman/mailman-bundler/bin/mailman digests --send
I wasn't aware that Core needed cron jobs too, is that true for 3.1 release as
well?
>
> I don't recall exactly where I saw that that was needed, but you can
> find it (except for the periodic digests bit) at
> <http://docs.list.org/en/latest/config-web.html#scheduled-tasks-required>.
> Note that that suggests a system crontab with the web server user rather
> than the 'mailman' user's crontab.
--
thanks,
Abhilash Raj
7 years, 10 months

[MM3-users] Re: What implications do GDPR have on Mailman, and how to requiring members to accept registration
by Stephen J. Turnbull
Henrik Rasmussen writes:
> What I meant was, that the list admin may be able to set the list
> to Open or Moderate, making it possible to subscribe others, and I
> was told by our GDPR folks that we have to make the subscribers
> re-confirm, so I was just trying to figure out a way to do it. I
> don't know very much about GDPR yet.
I think Mark misinterpreted "re-confirm". I assume you mean forcing
the *existing* subscribers to perform some action to confirm that they
still want to be subscribers. This is not currently a feature of
Mailman 2 or Mailman 3. We only can require confirmation at initial
subscription, except by something like unsubscribing or no-mail'ing
everybody as Mark suggested.
> I agree, I wouldn't remove [the mass subscription feature] either,
> but I just have to be concerned about the possibility that someone
> may have been subscribed against their will.
I think you would hear about that. Re-confirmation in light of new
rights for subscribers and responsibilities for providers seems
reasonable to me, but I think it's reasonable to assume list admins
are not malevolent.
In light of GDPR, we may need to develop ways to enforce site policy
about subscription confirmation and ability of users to unsubscribe
themselves at will.
> Is there a way to resend a confirmation request to either those who
> haven't been requested to confirm or alternately to all
> subscribers?
It seems to me that what most organizations are doing is not to force
reconfirmation, but rather informing their users of
1. their GDPR rights
2. what PII is present in the relevant databases
3. how to terminate the relationship if desired
In the case of Mailman, you might also want to
4. require SSL to access the website
5. advise the users to change their passwords if you had been
allowing access via HTTP or sending password reminders
For stock Mailman 2, this is not a big deal (I don't think any of the
subscriber configuration information is PII except display name and
address), but for Mailman 3 I believe there's some profile information
in HyperKitty that might be considered PII, and Mailman 3 will be
easier to extend using plugins etc to potentially incorporate even more.
Mark Sapiro writes:
> Or, post to the list that everyone will need to resubscribe and
> then remove everyone.
Note that this means that people who resubscribe late will miss mail.
That may or may not be a big deal.
Steve
7 years, 1 month

[MM3-users] Re: How to delete non-users
by Allan Hansen
Thank you, Stephen.
Yes, I have verified that the users will be subscribed once the moderator accepts their subscription requests.
The tricky time is between the non-member record is created and the moderator accepts the application.
Many of them will try to post before their subscription is approved (some moderators are good at procrastinating).
During this time the user thinks that the subscription has been entered, but is not able to send/receive messages.
Then they complain to me...
While some of the users and moderators may have visual impairments (well, it's possible that even a majority wears glasses - I do),
the bigger issue is that most are not techies, and some are very much not techies. They are brilliant in other ways and Mailman has been a wonderful tool for them all to communicate and organize, but it's also a bit quirky.
Yours,
Allan
On 9/16/22, 23:28 , "Stephen J. Turnbull" <stephenjturnbull(a)gmail.com> wrote:
Mark Sapiro writes:
> My original point is the presence of a nonmember role should not prevent
> the user from subscribing. If there is an issue with subscribing it is
> probably because of the outstanding subscription request waiting
> moderator approval.
I don't think it is likely, but is it possible that the moderator is
not just refusing the subscription, but banning the address from
subscribing?
> I understand that you would like the nonmember role to disappear, but
> that isn't going to happen in the distribution, and I can't undertake
> the extensive effort required to figure out how you can do it for your site.
It seems to me that explicitly displaying the nonmember role is an
internal and/or administrative need, and most ordinary users are only
interested in whether they are subscribed or not. If the list appears
in "their" list of list, they're going to assume they're subscribed.
(We've even had that confusion about moderators and owners in the
past.) I haven't done any deep thinking about this, but perhaps we
could provide a more streamlined view tuned to this specific need?
That is, the role won't go away, but at least in some contexts you'll
have to ask explicitly for that user-list relationship to be
displayed.
Also, IIRC Allan's community contains a substantial group of folks
with visual impairments, presumably including admins and moderators.
Especially to serve that circumstance I think it makes sense for us
to provide streamlined views that are more easily grasped as a whole
where we can.
_______________________________________________
Mailman-users mailing list -- mailman-users(a)mailman3.org
To unsubscribe send an email to mailman-users-leave(a)mailman3.org
https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/
2 years, 9 months

[MM3-users] Re: Clearing webserver cache - Nginx
by Odhiambo Washington
On Wed, Aug 7, 2024 at 2:08 AM Mark Sapiro <mark(a)msapiro.net> wrote:
> On 8/6/24 14:27, Mark Sapiro wrote:
> >
> > Is this with only one browser? It's a long shot, but clearing browser
> > cache might work.
>
>
> Actually, I see the same issues from my browsers, so it's not a browser
> caching issue. The only thing left is nginx caching, but, while I know
> very little about nginx, I think it doesn't cache by default and I don't
> see where in your posted config it's enabled. Perhaps there's more in
> your config that you didn't post.
>
There is nothing I didn't post :)
I finally found a way to purge the files cached by Cloudflare. It's in
their Dashboard.
But not before I had migrated everything to apache2!
So now I have all my sites configured in both webservers and I can use
whichever I like.
Right now I am using apache2, but I am seeing something odd:
https://mm3-lists.kictanet.or.ke/archives/ is empty. Is this normal?
I am expecting my most active list to appear there or am I overthinking?
Like this:
https://mm3-lists.kictanet.or.ke/archives/list/kictanet@lists.kictanet.or.k…
> If there is a proxy_cache_path directive in your config try
>
> find /the/proxy/cache/path -type f -delete
>
> to clear the cache.
>
There isn't. All the caching mess was coming from Cloudflare proxy servers.
If you host your DNS with CF, you will realize they proxy/cache your
traffic by
default unless you turn that off when creating an A record.
As a last resort, your /opt/mailman/mm/static/CACHE/ directory should
> contain a css/ directory with 3 files and a js directory containing one
> file and a manifest.json file with a template for the `link` directives
> referencing those files.
>
I have seen those files.
The js/ directory is easy as its only one file, so your server is
> looking for /static/CACHE/js/output.3aaa7705d68a.js and you could create
> a symlink in the js/ directory from output.3aaa7705d68a.js to the actual
> file. For the css directory, your server is looking for
> output.158acc288604.css and output.6dab123e4897.css, and I don't see the
> third file in the logs you posted, but if I go to pages in your archive
> that I see as unstyled and look at the stylesheet references, they are
> to output.44ea6c55e917.css, output.e68c4908b3de.css and
> output.9efeb5f3d52b.css so you could just symlink those to the actual
> files, it doesn't matter which as all three are loaded on each page
I did the symlinks and they helped with nginx, but because I have never had
to do that before, I did not like it.
That's why I switched to apache2 to see what the effects are and apache2
had/has no problem.
Because I have purged the CF cache, I reverted back to nginx and to see
from the logs what they are looking for:
```
root@eu:/opt/mailman/mm/static/CACHE/js# tail -f
/var/log/nginx/mm3-lists_error.log
2024/08/16 17:19:55 [error] 2403078#2403078: *62 open()
"/usr/share/nginx/html/static/CACHE/css/output.44ea6c55e917.css" failed (2:
No such file or directory), client: 172.70.111.111, server:
mm3-lists.kictanet.or.ke, request: "GET
/static/CACHE/css/output.44ea6c55e917.css HTTP/2.0", host: "
mm3-lists.kictanet.or.ke", referrer: "
https://mm3-lists.kictanet.or.ke/archives/"
^C
root@eu:/opt/mailman/mm/static/CACHE/js# cd ../css/
root@eu:/opt/mailman/mm/static/CACHE/css# ls -al
total 196
drwxr-xr-x 2 mailman mailman 4096 Aug 16 16:55 .
drwxr-xr-x 4 mailman mailman 4096 Mar 21 15:55 ..
-rw-r--r-- 1 mailman mailman 1209 Mar 21 15:55 output.d29798365ddb.css
-rw-r--r-- 1 mailman mailman 569 Mar 21 15:55 output.e68c4908b3de.css
-rw-r--r-- 1 mailman mailman 180904 Mar 21 15:55 output.e69dbb26da3b.css
root@eu:/opt/mailman/mm/static/CACHE/css#
```
So I am left wondering why nginx is prefixing "usr/share/nginx/html" to
/static.
I then decided to specify a root directive in the vhost pointing to
/opt/mailman/mm/static, and I saw nginx prefixing that path to the /static/
again:
```
root@eu:/opt/mailman/mm/static/CACHE/css# cp /dev/null
/var/log/nginx/mm3-lists_error.log
root@eu:/opt/mailman/mm/static/CACHE/css# tail -f
/var/log/nginx/mm3-lists_error.log
2024/08/16 17:28:11 [error] 2404382#2404382: *239 open()
"/opt/mailman/mm/static/static/CACHE/css/output.44ea6c55e917.css" failed
(2: No such file or directory), client: 172.70.111.112, server:
mm3-lists.kictanet.or.ke, request: "GET
/static/CACHE/css/output.44ea6c55e917.css HTTP/2.0", host: "
mm3-lists.kictanet.or.ke", referrer: "
https://mm3-lists.kictanet.or.ke/archives/list/kictanet@lists.kictanet.or.k…
"
```
Finally, I changed the root directory to /opt/mailman/mm and this time, I
see nginx getting the path correctly, but still looking for the same
nonexistent file from above
and another file:
```
root@eu:/opt/mailman/mm/static/CACHE/css# tail -f
/var/log/nginx/mm3-lists_error.log
2024/08/16 17:32:25 [error] 2405076#2405076: *38 open()
"/opt/mailman/mm/static/CACHE/css/output.44ea6c55e917.css" failed (2: No
such file or directory), client: 172.70.111.112, server:
mm3-lists.kictanet.or.ke, request: "GET
/static/CACHE/css/output.44ea6c55e917.css HTTP/2.0", host: "
mm3-lists.kictanet.or.ke", referrer: "
https://mm3-lists.kictanet.or.ke/archives/list/kictanet@lists.kictanet.or.k…
"
2024/08/16 17:36:17 [error] 2405080#2405080: *841 open()
"/opt/mailman/mm/static/CACHE/css/output.9efeb5f3d52b.css" failed (2: No
such file or directory), client: 108.162.238.56, server:
mm3-lists.kictanet.or.ke, request: "GET
/static/CACHE/css/output.9efeb5f3d52b.css HTTP/2.0", host: "
mm3-lists.kictanet.or.ke", referrer: "
https://mm3-lists.kictanet.or.ke/archives/list/kictanet@lists.kictanet.or.k…
"
```
From the above logs, that IP making requests is not my IP! It's the CF
proxies.
I then disabled the A record proxying for the site and accessed it from a
browser that I havven't used in months, and there was still some errors:
The IP showing is my IP.
```
root@eu:/opt/mailman/mm/static/CACHE/css# systemctl restart nginx
root@eu:/opt/mailman/mm/static/CACHE/css# tail -f
/var/log/nginx/mm3-lists_error.log
2024/08/16 17:41:11 [error] 2406218#2406218: *267 open()
"/opt/mailman/mm/static/CACHE/css/output.44ea6c55e917.css" failed (2: No
such file or directory), client: 185.199.102.24, server:
mm3-lists.kictanet.or.ke, request: "GET
/static/CACHE/css/output.44ea6c55e917.css HTTP/2.0", host: "
mm3-lists.kictanet.or.ke", referrer: "
https://mm3-lists.kictanet.or.ke/archives/list/kictanet@lists.kictanet.or.k…
"
2024/08/16 17:41:11 [error] 2406218#2406218: *267 open()
"/opt/mailman/mm/static/CACHE/css/output.9efeb5f3d52b.css" failed (2: No
such file or directory), client: 185.199.102.24, server:
mm3-lists.kictanet.or.ke, request: "GET
/static/CACHE/css/output.9efeb5f3d52b.css HTTP/2.0", host: "
mm3-lists.kictanet.or.ke", referrer: "
https://mm3-lists.kictanet.or.ke/archives/list/kictanet@lists.kictanet.or.k…
"
2024/08/16 17:41:12 [error] 2406218#2406218: *267 open()
"/opt/mailman/mm/static/CACHE/js/output.3aaa7705d68a.js" failed (2: No such
file or directory), client: 185.199.102.24, server: mm3-lists.kictanet.or.ke,
request: "GET /static/CACHE/js/output.3aaa7705d68a.js HTTP/2.0", host: "
mm3-lists.kictanet.or.ke", referrer: "
https://mm3-lists.kictanet.or.ke/archives/list/kictanet@lists.kictanet.or.k…
"
```
And the issue is something about accessing the archives.
Not sure if there is something to do for nginx to behave.
Apache does not display any single error.
--
Best regards,
Odhiambo WASHINGTON,
Nairobi,KE
+254 7 3200 0004/+254 7 2274 3223
In an Internet failure case, the #1 suspect is a constant: DNS.
"Oh, the cruft.", egrep -v '^$|^.*#' ¯\_(ツ)_/¯ :-)
[How to ask smart questions:
http://www.catb.org/~esr/faqs/smart-questions.html]
10 months, 2 weeks

[MM3-users] Re: No option 'postmap_command' in section: 'postfix'
by Odhiambo Washington
On Mon, Jan 30, 2023 at 8:35 PM Mark Sapiro <mark(a)msapiro.net> wrote:
> On 1/30/23 02:44, Odhiambo Washington wrote:
> > The documentation
> > <
> https://docs.mailman3.org/projects/mailman/en/latest/src/mailman/docs/mta.h…
> >
> > says that I need to create /path/to/postfix-mailman.cfg containing:
> > [postfix]
> > transport_file_type: regex
> >
> > Then append the path to the [mta] section of mailman.cfg, viz:
> >
> > [mta]
> ...
> > configuration: /path/to/postfix-mailman.cfg
> >
> > That is exactly what I have done on my test platform, but I get the error
> > below when creating a list.
> > Perhaps I overlooked something?
> ...
> > "/opt/mailman/venv/lib/python3.9/site-packages/mailman/mta/postfix.py",
> > line 87, in __init__
> > self.postmap_command = mta_config.get('postfix', 'postmap_command')
> > File "/usr/local/lib/python3.9/configparser.py", line 792, in get
> > raise NoOptionError(option, section)
> > configparser.NoOptionError: No option 'postmap_command' in section:
> > 'postfix'
>
> This is a bug. Whether it is a bug in documention or code is not
> completely clear. Current code requires there be a `postmap_command:`
> setting in the [postfix] configuration even though it isn't used if
> `transport_file_type:` is set to regex.
>
> You can fix this in one of two ways. Either apply this patch
> ```
> --- a/src/mailman/mta/postfix.py
> +++ b/src/mailman/mta/postfix.py
> @@ -84,9 +84,10 @@ class LMTP:
> def __init__(self):
> # Locate and read the Postfix specific configuration file.
> mta_config = external_configuration(config.mta.configuration)
> - self.postmap_command = mta_config.get('postfix',
> 'postmap_command')
> self.transport_file_type = mta_config.get(
> 'postfix', 'transport_file_type')
> + if self.transport_file_type == 'hash':
> + self.postmap_command = mta_config.get('postfix',
> 'postmap_command')
>
> def create(self, mlist):
> """See `IMailTransportAgentLifecycle`."""
> ```
> (watch for possible wrapped lines in above) or add
>
> postmap_command: unused
>
> to /path/to/postfix-mailman.cfg.
>
> Note however that hash tables for Postfix are more efficient than regex
> tables and the only reason we support regex tables is for a Docker
> container that doesn't have Postfix installed in the Mailman container.
>
So, if I understand this correctly, there is no need for the addition of
this parameter:
```
configuration: /path/to/postfix-mailman.cfg
```
to the mta config block in mailman.cfg in a non-docker environment, or when
only using hash tables??
--
Best regards,
Odhiambo WASHINGTON,
Nairobi,KE
+254 7 3200 0004/+254 7 2274 3223
"Oh, the cruft.", egrep -v '^$|^.*#' ¯\_(ツ)_/¯ :-)
2 years, 5 months

[MM3-users] Re: Confirmation emails to Users has wrong domain name (example.com!)
by Abhilash Raj
> On Sep 29, 2021, at 2:34 PM, Odhiambo Washington <odhiambo(a)gmail.com> wrote:
>
> On Wed, Sep 29, 2021 at 8:31 PM Mark Sapiro <mark(a)msapiro.net> wrote:
>
>> On 9/29/21 9:50 AM, Odhiambo Washington wrote:
>>> 1. Confirmation emails to Users has wrong domain name (example.com!)
>>> <https://docs.mailman3.org/en/latest/faq.html#id1>
>>> <
>> https://docs.mailman3.org/en/latest/faq.html#confirmation-emails-to-users-h…
>>>
>>>
>>> This happens when your reverse (SSL) proxy isn’t setting up the correct
>>> headers when proxying requests. Fix this by setting the right
>>> proxy_set_header directives:
>> ...
>>> How is this supposed to be mitigated in Apache when using WSGI?
>>>
>>> My config:
>>>
>>> WSGIDaemonProcess hyperkitty threads=25 python-path=/usr/local/mailman
>>> user=mailman group=mailman
>>> WSGIPythonHome "/usr/local"
>>> WSGIProcessGroup hyperkitty
>>
>>
>> You are using mod_wsgi and not proxying at all, so this is not relevant
>> in your case.
>>
>> Are you actually seeing this issue? If so, it might be related to
>>
>> https://docs.mailman3.org/en/latest/faq.html#the-domain-name-displayed-in-h…
>>
>
> My issue is related to this, but the documentation referred to is not for
> the faint-hearted!
> I can't make head or tails of it.
Click on “Domain” in Postorius from the top bar, which should take you to the Domains page.
For your domain (in the “Mail Host” column), see the corresponding “Web Host” column, it should look something like:
lists.mailman3.org (lists.mailman3.org)
(Edit)
SITE_ID = 1
on a new-ish version of Postorius.
If it doesn’t show the right values and instead shows “example.com” for you, click on the “Edit” link, which will take
you to a page that will allow you to edit both the values.
In that page, you can update “Domain name” to whatever your domain is (lists.xxx.xxx) and then “Display Name” can be anything else you want or the domain name itself. Click “Save” and then Click on “View Site” in the top right corner of the page to go back to Postorius.
Abhilas
>
>
> --
> Best regards,
> Odhiambo WASHINGTON,
> Nairobi,KE
> +254 7 3200 0004/+254 7 2274 3223
> "Oh, the cruft.", egrep -v '^$|^.*#' :-)
> _______________________________________________
> Mailman-users mailing list -- mailman-users(a)mailman3.org
> To unsubscribe send an email to mailman-users-leave(a)mailman3.org
> https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/
--
thanks,
Abhilash Raj (maxking)
3 years, 9 months

[MM3-users] Re: Moderate mails from owner
by Malcolm Austen
On Thu, 21 Mar 2019 17:27:01 -0000, Mark Sapiro <mark(a)msapiro.net> wrote:
> On 3/21/19 3:02 AM, Malcolm Austen wrote:
>>
>> My only experience of MM3 is with Ancestry's 'RootsWeb' installation.
>> From the emails I can see a header "X-Mailman-Version: 3.1.0" but I
>> can't find anything to identify Postorius which is the only interface I
>> have to the system.
>
> Isn't there a footer at the bottom of wach page with something like:
> Postorius Documentation • GNU Mailman • Postorius Version 1.2.5
Unfortunately not Mark, Ancestry/RootsWeb have a history of tailoring
Mailman heavily - and then deciding they don't have the resources to
update to a new version :-(
All there is on <https://lists.rootsweb.com/postorius/> is:
RootsWeb is funded and supported by Ancestry.com and our loyal RootsWeb
community. Learn more.
About Us | Contact Us | Rootsweb Blog | Copyright
© 1997-2018 Ancestry | Corporate Information | Privacy | Terms and
Conditions
>> From symptoms seen and described by others, I have deduced that the
>> Postorius admin-per-user moderation options of "Default processing" and
>> "List default" mean that a user may be set (by default on the rootsweb
>> system!) to use the system default moderation settings rather than the
>> list default settings.
>
> New (non-)members always have Moderation set to List default. This means
> their posts are governed by the applicable Settings -> Message
> Acceptance settings.
I suspect that everyone on the rootsweb system was mistakenly set to
'Default processing' when they were bulk-imported from Mailman2.
> Setting a user's Moderation to Default Processing means that users posts
> will not be held/rejected/discarded/accepted immediately based on
> "Default action to take when a (non-)member posts to the list", but
> additional checks will not be bypassed. See
> <https://mailman.readthedocs.io/en/latest/src/mailman/rules/docs/rules.html>.
I will read that, and whatever else I can.
>> Are my deductions correct? And if so, could this be the explanation of
>> the issue detailed in this thread?
>
> Setting a user's Moderation to Default Processing (or Accept) would
> bypass the list defaults and could be the explanation of this issue.
>
> When the non-member owner first posts to the list that address becomes a
> non-member of the list. I.e. it is in the roster of known non-members of
> the list and that non-member record could have had its Moderation set to
> Accept or Default Processing at some point which would explain why the
> posts are accepted.
Thanks for the explanation and link, Malcolm.
--
Malcolm Austen <malcolm.austen(a)weald.org.uk>
6 years, 3 months

[MM3-users] Re: missing graphics in Postorius
by David Newman
On 12/7/21 11:17 AM, Mark Sapiro wrote:
> On 12/6/21 10:15 PM, David Newman wrote:
>> After installing MM3 on Debian 10 using the venv docs, no graphics
>> appear in the admin or list pages, just broken links.
>>
>> The mailmanweb log has lines like this:
>>
>> ERROR 2021-12-07 06:04:10,002 18262 django.security.DisallowedHost
>> Invalid HTTP_HOST header: '127.0.0.1'. You may need to add '127.0.0.1'
>> to ALLOWED_HOSTS.
>>
>> which is odd because there is the line for "localhost" in settings.py,
>> and /etc/hosts correctly ties this to 127.0.0.1.
>
>
> Add '127.0.0.1' to ALLOWED_HOSTS anyway.
Done, thanks.
Given that DNS works fine on this host, with localhost and 127.0.0.1
resolving backward and forward, this seems like a bug. Shouldn't the
resolver be able to recognize localhost without hard-coding an address?
Particularly this address, since the IETF is considering what is IMO a
crazy idea to unreserve 127/8?
https://www.ietf.org/id/draft-schoen-intarea-unicast-127-00.html
>
>
>> There are entries like this in /var/log/nginx/error.log saying the
>> files just aren't there:
>>
>> 2021/12/06 22:00:30 [error] 18123#18123: *65 open()
>> "/opt/mailman/web/static/postorius/img/mailman_logo_small_trans.png"
>> failed (2: No such file or directory), client: x.x.x.x, server:
>> somehost.example.com, request: "GET
>> /static/postorius/img/mailman_logo_small_trans.png HTTP/2.0", host:
>> "somehost.example.com", referrer:
>> "https://somehost.example.com/mailman/lists/"
>>
>> (I've obfuscated names and addresses here, but "somehost.example.com"
>> refers to a valid FQDN in the log.)
>>
>> I thought I'd followed all the venv docs, but the
>> /opt/mailman/web/static/postorius directory doesn't exist. Did I miss
>> something?
>
> Assuming you have
> ```
> STATIC_ROOT = '/opt/mailman/web/static'
> ```
> in your /etc/mailman3/settings.py file, you may need to create that
> directory if it doesn't exist. You shouldn't need to manually create the
> /opt/mailman/web/static/postorius directory if the
> /opt/mailman/web/static directory exists and is writable/searchable by
> the Mailman user.
Yes, that was it. Thanks.
Previously you'd pointed out what you considered an error in the venv
docs, with the workaround to manually create the /opt/mailman/web
directory [1]. I think the same issue applies here, and also that
/opt/mailman/web and subdirectories need to be owned by the mailman user.
Thanks again.
dn
>
> That should enable
> ```
> (venv)$ mailman-web collectstatic
> ```
> to populate that directory. Be sure you've run all four commands at
> https://docs.mailman3.org/en/latest/install/virtualenv.html#run-database-mi…
> et seq.
>
3 years, 6 months

[MM3-users] Re: External MTA incoming mail: configuration
by Roland Giesler
On 2024/08/06 10:46, Odhiambo Washington via Mailman-users wrote:
> On Tue, Aug 6, 2024 at 10:46 AM Roland Giesler via Mailman-users <
> mailman-users(a)mailman3.org> wrote:
>
>> On 2024/08/05 19:59, Mark Sapiro wrote:
>>> If you really have local users on box2.gtahardware.co.za with
>>> addresses '@fast.za.net' and you want to relay list mail to lists
>>> '@fast.za.net', you need to see
>> https://docs.mailman3.org/projects/mailman/en/latest/src/mailman/docs/mta.h…
>> .
>>
>> Thank you for that! From that it seems it may still be possible to use
>> PMiaB as my MTA after, but I'll work through that reference and test it
>> and report back.
> I think that ALL MTAs have the concept of local domains (for which mails
> are delivered to 'local mailboxes') and remote domains (aka relay domains)
> for which mail is relayed to another host which has the mailboxes.
> So in your case box2.gtahardware.co.za (this is FQDN) could be handling
> local emails, e.groland@gtahardware.co.za,johndoe@gtahardware.co.za, etc.
> Those are local, and so gtahardware.co.za is a local domain. However,
> fast.za.net is a relay domain and all mail toXXX(a)fast.za.net should be
> relayed to the MM3 server.
> If your MTA does not have this concept, then it's either not ready for
> prime time or it wasn't intended to have such ability.
With Mail-in-a-box and it's fork Power-mail-in-a-box, the recipient
domain is created when an email address is added for which the box
should receive mail. When the last email address for a domain is
deleted, the domain is deleted too. More than that, the DNS zone file
for the domain is also created and so are certificates, aliases and
more. If I stick to that, then it's easy to run a mail server and
everything *just works*. This is why I don't want to remove any of the
MiaB settings.
If I therefore want to allow mail for fast.za.net onto
box2.gtahardware.co.za, then I need to have at least one mailbox for
that domain, or an email alias on that box. This of course complicates
matters for forwarding, since not all mail for fast.za.net must be
forwarded, only the mail that is not specifically configured on box2.
With Mark's link I think I may get this to work, but I need to still
impliment and test this. It will take a couple of days for me to get
around to it bit by bit (no pun intended!).
>
>
10 months, 3 weeks

[MM3-users] Re: Apache+mod_wsgi issue
by Odhiambo Washington
On Fri, Dec 23, 2022 at 9:21 AM Odhiambo Washington <odhiambo(a)gmail.com>
wrote:
>
>
> On Fri, Dec 23, 2022 at 4:29 AM Mark Sapiro <mark(a)msapiro.net> wrote:
>
>> On 12/22/22 16:03, Odhiambo Washington wrote:
>> >
>> > There is just one more thing - I have this in settings.py:
>> > LOGGING['handlers']['file']['filename'] =
>> > '/opt/mailman/mm/var/logs/mailmanweb.log'
>>
>>
>> And what are LOGGING['handlers']['file']['level'],
>> LOGGING['handlers']['file']['class'] and
>> LOGGING['handlers']['file']['formatter']
>>
>
> Those are left as defaults in my setup.py.
>
>
>> > However, the referenced file is ever empty. At what point is it
>> supposed to
>> > record anything?
>>
>> What is logged depends on `level` but even with `DEBUG` not much routine
>> stuff is logged. See
>> https://docs.djangoproject.com/en/3.2/topics/logging/
>
>
> I will read that and see if I get to pick up something.
>
> And now I am having a problem with mod_wsgi.
> First, the URL displayed when I load the page looks bogus to me.
> While I expect the URL to be
> https://mm3-lists.kictanet.or.ke/mailman3/domains/, mod_wsgi give me
> https://mm3-lists.kictanet.or.ke/mailman3/mailman3/domains/ - there is an
> extra /mailman3!
>
> So I have;
> 1. https://mm3-lists.kictanet.or.ke/mailman3/mailman3/lists/ - working,
> or appears to.
> 2. https://mm3-lists.kictanet.or.ke/mailman3/mailman3/domains/ - working,
> or appears to.
> 3. https://mm3-lists.kictanet.or.ke/mailman3/mailman3/bans/ - working, or
> appears to
> 4. https://mm3-lists.kictanet.or.ke/mailman3/mailman3/users - working, or
> appears to
> 5.
> https://mm3-lists.kictanet.or.ke/mailman3/mailman3/lists/kictanet.lists.kic…
> - This throws an exception error when I click "Manage Subscription".
>
> -> https://pastebin.ubuntu.com/p/RkKH793Jgw/
>
> And while I do not quite understand the error itself, there is also one
> particular line that I also saw that has left me baffled:
> [Fri Dec 23 08:53:18.290411 2022] [core:info] [pid 91236] [client
> 197.232.81.246:13865] AH00128: File does not exist:
> /usr/local/www/apache24/data/archives/list/
> kictanet(a)lists.kictanet.or.ke/thread/VIHCC6MSXZSNHY7YPEJ3D2US4N7MHJEC/,
> refe
> rer:
> https://mm3-lists.kictanet.or.ke/archives/list/kictanet@lists.kictanet.or.ke
>
>
I also need to add the fact that at the point where I am clicking "Manage
Subscription", the URL has changed to
https://mm3-lists.kictanet.or.ke/mailman3/archives/list/kictanet@lists.kict…
(just a single /mailman3).
--
Best regards,
Odhiambo WASHINGTON,
Nairobi,KE
+254 7 3200 0004/+254 7 2274 3223
"Oh, the cruft.", egrep -v '^$|^.*#' ¯\_(ツ)_/¯ :-)
2 years, 6 months

[MM3-users] Re: how to unhold a hold message from a nonmmeber in hold list.
by Odhiambo Washington
On Fri, Apr 21, 2023 at 12:04 PM Guillermo Hernandez (Oldno7) via
Mailman-users <mailman-users(a)mailman3.org> wrote:
>
> El 21/4/23 a las 10:37, Odhiambo Washington escribió:
> >
> >
> > On Fri, Apr 21, 2023 at 11:20 AM Guillermo Hernandez (Oldno7) via
> > Mailman-users <mailman-users(a)mailman3.org> wrote:
> >
> > I'm having troubles with Django and cannot access to web admin.
> >
> > I need to unhold a message while figures out what is happening.
> >
> > Searching the mailman cli help commands didn't help me.
> >
> > Anyone who knows how to unhold a message, please?
> >
> >
> > TBH, I find it a lot easier to fix the web UI than mess with the
> > python shell :-)
> >
> > While you wait for @Mark Sapiro <mailto:mark@msapiro.net> to save you,
> > you can be reading the following:
> >
> >
> https://docs.mailman3.org/projects/mailmanclient/en/latest/src/mailmanclien…
>
> Thanks: it seems the place to do it (I didn't find it)
>
> I'm fighting the web UI problem. It seems that something in wsgi has
> changed and is no more compatible with my version of things. Error log
> from apache shows:
>
> mod_wsgi (pid=30632): Failed to exec Python script file
> '/usr/local/mailman3/wsgi.py'.
> mod_wsgi (pid=30632): Exception occurred processing WSGI script
> '/usr/local/mailman3/wsgi.py'.
> Traceback (most recent call last):
> File "/usr/local/mailman3/wsgi.py", line 34, in <module>
> from django.core.wsgi import get_wsgi_application
> File "/usr/local/lib/python3.9/site-packages/django/core/wsgi.py", line
> 2, in <module>
> from django.core.handlers.wsgi import WSGIHandler
> File
> "/usr/local/lib/python3.9/site-packages/django/core/handlers/wsgi.py",
> line 3, in <module>
> from django.conf import settings
> File "/usr/local/lib/python3.9/site-packages/django/conf/__init__.py",
> line 19, in <module>
> from django.utils.deprecation import RemovedInDjango50Warning,
> RemovedInDjango51Warning
> File
> "/usr/local/lib/python3.9/site-packages/django/utils/deprecation.py",
> line 4, in <module>
> from asgiref.sync import iscoroutinefunction, markcoroutinefunction,
> sync_to_async
> ImportError: cannot import name 'iscoroutinefunction' from
> 'asgiref.sync' (/usr/local/lib/python3.9/site-packages/asgiref/sync.py)
>
If you did some system updates then that is where you need to check.
Obviously, something did update, leading to the breakage.
--
Best regards,
Odhiambo WASHINGTON,
Nairobi,KE
+254 7 3200 0004/+254 7 2274 3223
"Oh, the cruft.", egrep -v '^$|^.*#' ¯\_(ツ)_/¯ :-)
[How to ask smart questions:
http://www.catb.org/~esr/faqs/smart-questions.html]
2 years, 2 months

[MM3-users] Re: Postorius no connection to REST API
by Richard Rosner
Mark Sapiro wrote:
> > But whatever is listening on port 8001 is apparently not Mailman's rest
> server. What does
> ps -fww 14080
> or whatever PID is currently listening on port 8001 show.
UID PID PPID C STIME TTY STAT TIME CMD
list 15972 15963 0 Aug11 ? Sl 0:13 /usr/bin/python3 /usr/lib/mailman3/bin/runner -C /etc/mailman3/mailman.cfg --runner=rest:0:1
> > OK.
> Perhaps instead you should have
> uid: list
> gid: list
> in your uwsgi configuration if you don't already.
Tried that while also switching mailman3-web.service to list:list, exactly the same error. Also, I have /run/mailman3-web/uwsgi.sock owned by list:list now instead of www-data:www-data.
What the logs say:
*** Starting uWSGI 2.0.18-debian (64bit) on [Thu Aug 12 08:46:37 2021] ***
compiled with version: 8.2.0 on 10 February 2019 02:42:46
os: Linux-4.19.0-16-amd64 #1 SMP Debian 4.19.181-1 (2021-03-19)
nodename: mail
machine: x86_64
clock source: unix
pcre jit disabled
detected number of CPU cores: 2
current working directory: /
detected binary path: /usr/bin/uwsgi-core
chdir() to /usr/share/mailman3-web
your processes number limit is 3831
your memory page size is 4096 bytes
detected max file descriptor number: 1024
lock engine: pthread robust mutexes
thunder lock: disabled (you can enable it with --thunder-lock)
error removing unix socket, unlink(): Permission denied [core/socket.c line 198]
bind(): Address already in use [core/socket.c line 230]
Not sure if that means the two directories need to be owned by list, currently they are owned by root
> > I'm not familiar enough with this form of ProxyPass using sockets to
> understand what the localhost:8001 does in this context, but uwsgi
> should not be doing anything with port 8001. In a configuration using
> TCP, it would listen on port 8000. Port 8001 is where Mailman's REST API
> server listens. uwsgi should receive connects in your case via the unix
> socket and then pass them to Django via the application in wsgi.py
> Also, you may want other paths proxied to uwsgi, namely at least some of
> hyperkitty, postorius, archives, accounts, admin and user-profile.
Ok, I removed that port again, now it's exctly like in the automatically generated config file.
And you mean like
<IfModule mod_proxy_uwsgi.c>
ProxyPass /mailman3/favicon.ico !
ProxyPass /mailman3/static !
ProxyPass /mailman3 unix:/run/mailman3-web/uwsgi.sock|uwsgi://localhost/
ProxyPass /hyperkitty unix:/run/mailman3-web/uwsgi.sock|uwsgi://localhost/
ProxyPass /postorius unix:/run/mailman3-web/uwsgi.sock|uwsgi://localhost/
ProxyPass /admin unix:/run/mailman3-web/uwsgi.sock|uwsgi://localhost/
ProxyPass /archives unix:/run/mailman3-web/uwsgi.sock|uwsgi://localhost/
ProxyPass /accounts unix:/run/mailman3-web/uwsgi.sock|uwsgi://localhost/
ProxyPass /user-profile unix:/run/mailman3-web/uwsgi.sock|uwsgi://localhost/
</IfModule>
> > These should be 'list', not 'www-data'. That's your permissions issue on
> settings.py
3 years, 10 months

[MM3-users] Re: disabled users
by Servizio Informatico U.I.C.I. Sezione territoriale di Brescia
Hello,
Thank you for your answers. The problem is:
I have a lot of user disabled for too many bounces. These users have the
same provider that, probably, has some limits of number of mail that can
be delivered from the same server. This causes timeout connections and,
mailman creates correctly a bounce.
So I would like to discover a way to reset bounce limits so they can be
re enabled to receive. I tried also to unsubscribe and resubscribe users
but it does not change anything.
Thank you
Roberto Burceni
Servizio informatico sezionale
Tel. 0302209417 (lunedì e giovedì mattina dalle 9:00 alle 13:00, martedì emercoledì pomeriggio dalle 14:00 alle 18:00
E-mail:
servizioinformatico(a)uicibrescia.it
Sito web: https://www.uicibrescia.it
Il 26/10/23 00:13, Mark Sapiro ha scritto:
> On 10/25/23 10:44 AM, Stephen J. Turnbull wrote:
>> Servizio Informatico U.I.C.I. Sezione territoriale di Brescia writes:
>>
>> > Wher I find the disabled user of a mailing list and wher I can
>> > reactivate them?
>>
>> If you are the list owner or superuser, when you visit the list's
>> information page there will be a horizontal menu across the top. One
>> of the entries is Users. Click to open the dropdown menu and choose
>> Members. There doesn't seem to be an explicit notation for disabled
>> users, but if the entry in the far right column "bounce score" is
>> None, the member may be disabled.
>
> I don't think this is correct. Members with delivery disabled by
> bounce will normally show 0 rather than None for bounce score.
>
> If you have shell access to the server as the Mailman user, you can
> run this shell interaction to find members with delivery disabled by
> bounce.
> ```
> $ mm/bin/mailman shell -l test(a)example.com
> Welcome to the GNU Mailman shell
> Use commit() to commit changes.
> Use abort() to discard changes since the last commit.
> Exit with ctrl+D does an implicit commit() but exit() does not.
> The variable 'm' is the test(a)example.com mailing list
> >>> for member in m.members.members:
> ... if member.delivery_status == DeliveryStatus.by_bounces:
> ... print(member.address.email)
> ...
> >>>
> ```
> But the question is, why do you want to re-enable their delivery.
> Granted, there are situations such as a misconfigured MTA or not
> applying needed DMARC mitigations that could result in 'spurious'
> bounced deliveries, but normally bounce processing disables delivery,
> sends warnings to the bouncing address and ultimately unsubscribes
> them because the address it truly not deliverable.
>
>
1 year, 8 months

[MM3-users] Re: Huge performance issue: Mailman doesn't (seem to) receive any mails.
by Mark Sapiro
On 9/20/19 5:39 AM, Henrik Rasmussen wrote:
> I know this is quite long (sorry), but I hope this part of the mailman.log may provide some clue to what went wrong.
It doesn't.
> As mentioned, Mailman stopped receiving mails some days ago and I have been restarting Mailman (without solving anything) at Sep 18 13:30:03 2019. On Sep 20 07:05:23 2019 everything started working again by itself.
>
> / Henrik Rasmussen
>
I'm snipping a bunch of irrelevant stuff having to do with web
interactions, etc.
> Sep 20 06:42:22 2019 (35) HOLD: listname(a)lists.example.com post from someone(a)foo.bar held, message-id=<4E8DB72B-66D9-456E-B51C-2A49423CF29F(a)foo.bar>: The message comes from a moderated member
> Sep 20 06:42:23 2019 (35) ACCEPT: <CALcvC6H5ko14LT8F_z_nbddp0DmDgfb-Rt32s+0TbpPrY3BL_g(a)mail.foo.bar>
There are lots of these indicating messages have been received via LMTP
and passed to Core.
> Sep 20 06:42:48 2019 (35) ACCEPT: <CAG3z+4+67M9jAjbVtSqUdUCU6cS1dOYBsmMTAdePL3+O+Nn+sQ(a)mail.foo.bar>
> Sep 20 06:42:56 2019 (32) Exception in the HyperKitty archiver: 'url'
> Sep 20 06:42:56 2019 (32) Traceback (most recent call last):
> File "/usr/local/lib/python3.6/site-packages/mailman_hyperkitty/__init__.py", line 154, in _archive_message
> url = self._send_message(mlist, msg)
> File "/usr/local/lib/python3.6/site-packages/mailman_hyperkitty/__init__.py", line 217, in _send_message
> archived_url = result["url"]
> KeyError: 'url'
> Sep 20 06:42:57 2019 (32) Exception in the HyperKitty archiver: 'url'
> Sep 20 06:42:57 2019 (32) Traceback (most recent call last):
> File "/usr/local/lib/python3.6/site-packages/mailman_hyperkitty/__init__.py", line 154, in _archive_message
> url = self._send_message(mlist, msg)
> File "/usr/local/lib/python3.6/site-packages/mailman_hyperkitty/__init__.py", line 217, in _send_message
> archived_url = result["url"]
> KeyError: 'url'
> Sep 20 06:42:57 2019 (32) HyperKitty failure on http://mailman-web:8000/hyperkitty/api/mailman/archive:
>
> <!DOCTYPE html>
> <html lang="en">
> <head>
> <meta charset="UTF-8">
> <meta http-equiv="X-UA-Compatible" content="IE=edge">
> <meta name="viewport" content="width=device-width, initial-scale=1">
> <title>Server Error</title>
> <link rel="shortcut icon" href="/static/postorius/img/favicon.ico">
> <link rel="stylesheet" href="/static/postorius/libs/bootstrap/css/bootstrap.min.css">
> <link rel="stylesheet" href="/static/django-mailman3/css/main.css">
> <link rel="stylesheet" href="/static/postorius/css/style.css">
>
> <!-- HTML5 shim and Respond.js for IE8 support of HTML5 elements and media queries -->
> <!-- WARNING: Respond.js doesn't work if you view the page via file:// -->
> <!--[if lt IE 9]>
> <script src="/static/postorius/libs/html5shiv/html5shiv.min.js"></script>
> <script src="/static/postorius/libs/respond/respond.min.js"></script>
> <![endif]-->
> </head>
> <body>
> <div class="container">
> <h1>Server error</h1>
> <div class="alert alert-danger">An error occurred while processing your request.</div>
> </div>
> </body>
> </html>
> (500)
> Sep 20 06:42:57 2019 (32) Exception in the HyperKitty archiver:
>
> <!DOCTYPE html>
> <html lang="en">
> <head>
> <meta charset="UTF-8">
> <meta http-equiv="X-UA-Compatible" content="IE=edge">
> <meta name="viewport" content="width=device-width, initial-scale=1">
> <title>Server Error</title>
> <link rel="shortcut icon" href="/static/postorius/img/favicon.ico">
> <link rel="stylesheet" href="/static/postorius/libs/bootstrap/css/bootstrap.min.css">
> <link rel="stylesheet" href="/static/django-mailman3/css/main.css">
> <link rel="stylesheet" href="/static/postorius/css/style.css">
>
> <!-- HTML5 shim and Respond.js for IE8 support of HTML5 elements and media queries -->
> <!-- WARNING: Respond.js doesn't work if you view the page via file:// -->
> <!--[if lt IE 9]>
> <script src="/static/postorius/libs/html5shiv/html5shiv.min.js"></script>
> <script src="/static/postorius/libs/respond/respond.min.js"></script>
> <![endif]-->
> </head>
> <body>
> <div class="container">
> <h1>Server error</h1>
> <div class="alert alert-danger">An error occurred while processing your request.</div>
> </div>
> </body>
> </html>
> Sep 20 06:42:57 2019 (32) Traceback (most recent call last):
> File "/usr/local/lib/python3.6/site-packages/mailman_hyperkitty/__init__.py", line 154, in _archive_message
> url = self._send_message(mlist, msg)
> File "/usr/local/lib/python3.6/site-packages/mailman_hyperkitty/__init__.py", line 210, in _send_message
> raise ValueError(result.text)
> ValueError:
>
> <!DOCTYPE html>
> <html lang="en">
> <head>
> <meta charset="UTF-8">
> <meta http-equiv="X-UA-Compatible" content="IE=edge">
> <meta name="viewport" content="width=device-width, initial-scale=1">
> <title>Server Error</title>
> <link rel="shortcut icon" href="/static/postorius/img/favicon.ico">
> <link rel="stylesheet" href="/static/postorius/libs/bootstrap/css/bootstrap.min.css">
> <link rel="stylesheet" href="/static/django-mailman3/css/main.css">
> <link rel="stylesheet" href="/static/postorius/css/style.css">
>
> <!-- HTML5 shim and Respond.js for IE8 support of HTML5 elements and media queries -->
> <!-- WARNING: Respond.js doesn't work if you view the page via file:// -->
> <!--[if lt IE 9]>
> <script src="/static/postorius/libs/html5shiv/html5shiv.min.js"></script>
> <script src="/static/postorius/libs/respond/respond.min.js"></script>
> <![endif]-->
> </head>
> <body>
> <div class="container">
> <h1>Server error</h1>
> <div class="alert alert-danger">An error occurred while processing your request.</div>
> </div>
> </body>
> </html>
>
> Sep 20 06:42:57 2019 (32) HyperKitty failure on http://mailman-web:8000/hyperkitty/api/mailman/archive:
>
> <!DOCTYPE html>
> <html lang="en">
> <head>
> <meta charset="UTF-8">
> <meta http-equiv="X-UA-Compatible" content="IE=edge">
> <meta name="viewport" content="width=device-width, initial-scale=1">
> <title>Server Error</title>
> <link rel="shortcut icon" href="/static/postorius/img/favicon.ico">
> <link rel="stylesheet" href="/static/postorius/libs/bootstrap/css/bootstrap.min.css">
> <link rel="stylesheet" href="/static/django-mailman3/css/main.css">
> <link rel="stylesheet" href="/static/postorius/css/style.css">
>
> <!-- HTML5 shim and Respond.js for IE8 support of HTML5 elements and media queries -->
> <!-- WARNING: Respond.js doesn't work if you view the page via file:// -->
> <!--[if lt IE 9]>
> <script src="/static/postorius/libs/html5shiv/html5shiv.min.js"></script>
> <script src="/static/postorius/libs/respond/respond.min.js"></script>
> <![endif]-->
> </head>
> <body>
> <div class="container">
> <h1>Server error</h1>
> <div class="alert alert-danger">An error occurred while processing your request.</div>
> </div>
> </body>
> </html>
> (500)
> Sep 20 06:42:57 2019 (32) Exception in the HyperKitty archiver:
>
> <!DOCTYPE html>
> <html lang="en">
> <head>
> <meta charset="UTF-8">
> <meta http-equiv="X-UA-Compatible" content="IE=edge">
> <meta name="viewport" content="width=device-width, initial-scale=1">
> <title>Server Error</title>
> <link rel="shortcut icon" href="/static/postorius/img/favicon.ico">
> <link rel="stylesheet" href="/static/postorius/libs/bootstrap/css/bootstrap.min.css">
> <link rel="stylesheet" href="/static/django-mailman3/css/main.css">
> <link rel="stylesheet" href="/static/postorius/css/style.css">
>
> <!-- HTML5 shim and Respond.js for IE8 support of HTML5 elements and media queries -->
> <!-- WARNING: Respond.js doesn't work if you view the page via file:// -->
> <!--[if lt IE 9]>
> <script src="/static/postorius/libs/html5shiv/html5shiv.min.js"></script>
> <script src="/static/postorius/libs/respond/respond.min.js"></script>
> <![endif]-->
> </head>
> <body>
> <div class="container">
> <h1>Server error</h1>
> <div class="alert alert-danger">An error occurred while processing your request.</div>
> </div>
> </body>
> </html>
> Sep 20 06:42:57 2019 (32) Traceback (most recent call last):
> File "/usr/local/lib/python3.6/site-packages/mailman_hyperkitty/__init__.py", line 154, in _archive_message
> url = self._send_message(mlist, msg)
> File "/usr/local/lib/python3.6/site-packages/mailman_hyperkitty/__init__.py", line 210, in _send_message
> raise ValueError(result.text)
> ValueError:
>
> <!DOCTYPE html>
> <html lang="en">
> <head>
> <meta charset="UTF-8">
> <meta http-equiv="X-UA-Compatible" content="IE=edge">
> <meta name="viewport" content="width=device-width, initial-scale=1">
> <title>Server Error</title>
> <link rel="shortcut icon" href="/static/postorius/img/favicon.ico">
> <link rel="stylesheet" href="/static/postorius/libs/bootstrap/css/bootstrap.min.css">
> <link rel="stylesheet" href="/static/django-mailman3/css/main.css">
> <link rel="stylesheet" href="/static/postorius/css/style.css">
>
> <!-- HTML5 shim and Respond.js for IE8 support of HTML5 elements and media queries -->
> <!-- WARNING: Respond.js doesn't work if you view the page via file:// -->
> <!--[if lt IE 9]>
> <script src="/static/postorius/libs/html5shiv/html5shiv.min.js"></script>
> <script src="/static/postorius/libs/respond/respond.min.js"></script>
> <![endif]-->
> </head>
> <body>
> <div class="container">
> <h1>Server error</h1>
> <div class="alert alert-danger">An error occurred while processing your request.</div>
> </div>
> </body>
> </html>
>
> Sep 20 06:42:57 2019 (32) Exception in the HyperKitty archiver: 'url'
> Sep 20 06:42:57 2019 (32) Traceback (most recent call last):
> File "/usr/local/lib/python3.6/site-packages/mailman_hyperkitty/__init__.py", line 154, in _archive_message
> url = self._send_message(mlist, msg)
> File "/usr/local/lib/python3.6/site-packages/mailman_hyperkitty/__init__.py", line 217, in _send_message
> archived_url = result["url"]
> KeyError: 'url'
> Sep 20 06:42:57 2019 (32) Exception in the HyperKitty archiver: 'url'
> Sep 20 06:42:57 2019 (32) Traceback (most recent call last):
> File "/usr/local/lib/python3.6/site-packages/mailman_hyperkitty/__init__.py", line 154, in _archive_message
> url = self._send_message(mlist, msg)
> File "/usr/local/lib/python3.6/site-packages/mailman_hyperkitty/__init__.py", line 217, in _send_message
> archived_url = result["url"]
> KeyError: 'url'
There are lots of the above errors/tracebacks. They are a problem, but
not specifically the one affecting Postfix delivery.
There are two different tracebacks. The ValueError is because the
mailman_hyperkitty shim has called Hyperkitty via
http://mailman-web:8000/hyperkitty/api/mailman/archive to archive the
message and HyperKitty returned a 500 status with the HTML
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Server Error</title>
<link rel="shortcut icon" href="/static/postorius/img/favicon.ico">
<link rel="stylesheet"
href="/static/postorius/libs/bootstrap/css/bootstrap.min.css">
<link rel="stylesheet" href="/static/django-mailman3/css/main.css">
<link rel="stylesheet" href="/static/postorius/css/style.css">
<!-- HTML5 shim and Respond.js for IE8 support of HTML5 elements and
media queries -->
<!-- WARNING: Respond.js doesn't work if you view the page via
file:// -->
<!--[if lt IE 9]>
<script
src="/static/postorius/libs/html5shiv/html5shiv.min.js"></script>
<script src="/static/postorius/libs/respond/respond.min.js"></script>
<![endif]-->
</head>
<body>
<div class="container">
<h1>Server error</h1>
<div class="alert alert-danger">An error occurred while processing
your request.</div>
</div>
</body>
</html>
Then the KeyError occurs because the response did not include the URL of
the archived message.
When this occurs, mailman_hyperkitty retries the message until it succeeds.
For more information on the HyperKitty issue, look in the Django log
whose path is defined in LOGGING['handlers']['file']['filename'] in the
Django settings.
--
Mark Sapiro <mark(a)msapiro.net> The highway is for gamblers,
San Francisco Bay Area, California better use your sense - B. Dylan
5 years, 9 months

[MM3-users] Re: A little stuck with installation of MM3 - ModuleNotFoundError: No module named 'flufl.lock'
by Odhiambo Washington
On Thu, 30 Jul 2020 at 22:02, Mark Sapiro <mark(a)msapiro.net> wrote:
> On 7/30/20 11:24 AM, Odhiambo Washington wrote:
>
> > This works - I mean changes the error message to
> >
> > [Thu Jul 30 18:11:50.269667 2020] [wsgi:error] [pid 7627] [remote
> > 197.232.81.246:63962]
> >
> /opt/mailman/mm/venv/lib/python3.7/site-packages/readme_renderer-26.0-py3.7.egg/readme_renderer/markdown.py:38:
> > UserWarning: Markdown renderers are not available. Install
> > 'readme_renderer[md]' to enable Markdown rendering.
> > [Thu Jul 30 18:11:50.269700 2020] [wsgi:error] [pid 7627] [remote
> > 197.232.81.246:63962] warnings.warn(_EXTRA_WARNING)
>
>
> I'm not sure why you are getting this warning, and it's non-fatal, but
> you can get rid of it by
>
> pip install cmarkgfm
>
> in your virtualenv.
>
(venv) [mailman3@gw ~]$ pip install cmarkgfm
Requirement already satisfied: cmarkgfm in
./mm/venv/lib/python3.7/site-packages/cmarkgfm-0.4.2-py3.7-freebsd-12.1-RELEASE-p7-amd64.egg
(0.4.2)
Requirement already satisfied: cffi>=1.0.0 in
./mm/venv/lib/python3.7/site-packages/cffi-1.14.0-py3.7-freebsd-12.1-RELEASE-p7-amd64.egg
(from cmarkgfm) (1.14.0)
Requirement already satisfied: pycparser in
./mm/venv/lib/python3.7/site-packages/pycparser-2.20-py3.7.egg (from
cffi>=1.0.0->cmarkgfm) (2.20)
(venv) [mailman3@gw ~]$
> > [Thu Jul 30 21:11:50.573233 2020] [authz_core:error] [pid 10846] [client
> > 197.232.81.246:63962] AH01630: client denied by server configuration:
> > /var/spool/mailman-web, referer:
> > http://mm3-lists.my.server/mm3/mailman3/lists/
> >
> > There is NO /var/spool/mailman-web anywhere. It has not been created.
> > You mentioned that it should be created automatically, IIRC.
>
>
> No. I think I told you that the references to
> /var/spool/mailman-web/static in your Apache config should be changed to
> /opt/mailman/mm/static and that directory would be created/populated by
> mailman-post-update.
>
> I think you still have
>
> Alias /static "/var/spool/mailman-web/static"
>
> in your Apache config and it needs to be
>
> Alias /static "/opt/mailman/mm/static"
>
> That may be my fault as when I recently edited
> <
> https://wiki.list.org/DOC/Mailman%203%20installation%20experience?action=At…
> >,
> I missed that line.
After changing the Alias line and running the mailman-post-update, all
errors are gone and I have a web UI. Yayi!!!
I have been able to create a domain, a list for testing. Now I just need to
go through the analysis of what I have been doing so
that I can clean up my notes.
Then I can come back on migration issues.
A BIG THANK YOU for all the support up to this point.
--
Best regards,
Odhiambo WASHINGTON,
Nairobi,KE
+254 7 3200 0004/+254 7 2274 3223
"Oh, the cruft.", grep ^[^#] :-)
4 years, 11 months

[MM3-users] Re: Archiver "prototype" and disabling archiving at all
by Torge Riedel
Am 28.03.19 um 17:45 schrieb Abhilash Raj:
> On Thu, Mar 28, 2019, at 9:18 AM, Torge Riedel wrote:
>> Am 24.03.19 um 16:49 schrieb Mark Sapiro:
>>> On 3/24/19 5:40 AM, Torge Riedel wrote:
>>>> in the settings of a mailing list I can choose two archivers:
>>>> "Hyperkitty" and "prototype". What is this archive "prototype" and how
>>>> can I disable/remove/deinstall it? And how can I disable archiving at
>>>> all, so no archiver can be chosen in the settings.
>>> The prototype archiver stores messages individually in
>>> var/archives/prototype/LIST_NAME/.
>>>
>>> You can disable the prototype archiver by putting
>>>
>>> [archiver.prototype]
>>> enable: no
>>>
>>> in your mailman.cfg. To disable all archiving, just remove all the
>>> [archiver.*] sections from your mailman.cfg or set them to 'enable: no'
>>>
>>>
>> Hi Mark,
>>
>> thanks. This disabled the archivers, but there is still the "Archives"
>> link on top of the page. Is it possible to remove it? Cause there is
>> nothing to see there. I tried commenting "'hyperkitty'," in
>> INSTALLED_APPS, but then I got a 500.
> INSTALLED_APPS = (
> 'postorius',
> 'django_mailman3',
> # Uncomment the next line to enable the admin:
> 'django.contrib.admin',
> # Uncomment the next line to enable admin documentation:
> # 'django.contrib.admindocs',
> 'django.contrib.auth',
> 'django.contrib.contenttypes',
> 'django.contrib.sessions',
> 'django.contrib.sites',
> 'django.contrib.messages',
> 'django.contrib.staticfiles',
> 'django_gravatar',
> 'allauth',
> 'allauth.account',
> 'allauth.socialaccount',
> )
>
>
> This is how it should look like if you want to remove Hyperkitty. There
> are a few other settings you should remove.
>
> https://gitlab.com/mailman/postorius/blob/master/example_project/settings.py
>
> This is a Postorius only configuration for reference.
>
>
>> _______________________________________________
>> Mailman-users mailing list -- mailman-users(a)mailman3.org
>> To unsubscribe send an email to mailman-users-leave(a)mailman3.org
>> https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/
>>
Hi,
I gave it a try, but I was not able to disable hyperkitty. I compared the settings in the link you gave and I see a lot of differences. Some of them I am not sure why they are missing in other example settings.
Currently I would say, I will keep the archive link there until it is more clear for me how to set things up. Since archiving is disabled, there will be no data in the archive. That is okay for the moment.
Regards
Torge
6 years, 2 months

[MM3-users] Re: Hyperkitty not receaving messages / empty archive [Django] ERROR (EXTERNAL IP): Internal Server Error: /hyperkitty/api/mailman/urls
by Helge Baumgart
Hello Mark,
THANK You for identifying MY typos.... how embarrassing. :-)
Now ist running like a charm.
It's always the same...
These Variables are setting the internal Values via the docker-compose.yml.
If they do not match, the internal variables are not set.
Therefor my typo H*A*YPERKITTY_API_KEY =! HYPERKITTY_API_KEY caused,
that the mailman-web section of the docker-compose.yml had NO Hyperkitty
API- KEY.
I suspected something like that, that's why i set the key via the .env
variabels to ensure
identical values in all sections oft the docker.compose.yml.
I didn't check the name of the variables...
Thx again!
Best wishes
Helge
Ps.:
That docker-compose.yml with the settings_locale.py and
mailman_extra.cfg basically setts a complete deployable environment
INCLUDING the MTA,
which is independent of the host...
Am 22.01.2025 um 06:36 schrieb Mark Sapiro:
> On 1/21/25 05:44, Helge Baumgart wrote:
>
>> Hyperkitty-Api-Key in the docker-compose.yml is set via .env
>> Variabel, so it should be identical.
>
>
> I don't know how this works in the Docker image, but ...
>
>> Traceback (most recent call last):
>> File
>> "/usr/lib/python3.11/site-packages/django/core/handlers/exception.py",
>> line 56, in inner
>> response = get_response(request)
>> File
>> "/usr/lib/python3.11/site-packages/django/core/handlers/base.py",
>> line 197, in _get_response
>> response = wrapped_callback(request, *callback_args,
>> **callback_kwargs)
>> File
>> "/usr/lib/python3.11/site-packages/hyperkitty/views/mailman.py", line
>> 109, in _decorator
>> not hmac.compare_digest(
>>
>> Exception Type: TypeError at /hyperkitty/api/mailman/urls
>> Exception Value: unsupported operand types(s) or combination of
>> types: 'str' and 'NoneType'
>
> The above code is doing
>
> auth = authorization.split()
> if (len(auth) != 2 or auth[0] != 'Token' or
> not hmac.compare_digest(
> auth[1], settings.MAILMAN_ARCHIVER_KEY)):
>
>
> and the exception says either auth[0] is None or auth[1] or
> settings.MAILMAN_ARCHIVER_KEY is None.
>
> But
>
>> META:
> ...
>> HTTP_AUTHORIZATION = 'Token (value)'
> and
>
>> Settings:
>> Using settings module settings
> ...
>> MAILMAN_ARCHIVER_KEY = '********************'
>
> So The Authorization header is the appropriate `Token value` which
> should result in auth[0] being 'Token', auth[1] being the value and
> MAILMAN_ARCHIVER_KEY is set
>
>> That is my docker-compose.yml:
> ...
>> mailman-web:
> ...
>> - HAYPERKITTY_API_KEY=${MM3_HYPERKITTY_API_KEY}
>> #someapikey_longAndTrustworty
>
>
> I don't really understand why the above typo (HAYPERKITTY_API_KEY, not
> HYPERKITTY_API_KEY) would cause this error, but it needs to be fixed.
>
5 months, 1 week

[MM3-users] Re: Welcome message template errors
by Mark
On 2024-04-22 14:07, Mark Sapiro wrote:
> I think you must be setting the custom template via Postorius and
> your Django setting for POSTORIUS_TEMPLATE_BASE_URL is wrong. It
> should be set to the scheme and host you use to access Postorius. I.e,
> if you normally access Postorius via something like
> https://example.com/mailman3 set
>
> POSTORIUS_TEMPLATE_BASE_URL = 'https://example.com'
>
> It is probably now set as
>
> POSTORIUS_TEMPLATE_BASE_URL = 'http://<REDACTED-PUBLIC-IPv4-ADDRESS>'
================================================================================
There was no line POSTORIUS_TEMPLATE_BASE_URL in
/etc/mailman3/settings.py
So I've now added the line: POSTORIUS_TEMPLATE_BASE_URL =
'https://lists.mydomain.com'
Checked in settings.py that:
- "lists.mydomain.com" is in ALLOWED_HOSTS; and
- "https://lists.mydomain.com" is in CSRF_TRUSTED_ORIGINS
Restarted everything...
rm /opt/mailman/mm/var/locks/*
systemctl restart mailman3
systemctl restart mailmanweb
systemctl daemon-reload
systemctl restart qcluster
# pstree
systemd─┬─
├─gunicorn───gunicorn
├─mailman-web───mailman-web───4*[mailman-web]
├─nginx───2*[nginx]
├─postgres───18*[postgres]
├─python3─┬─11*[python3]
│ ├─python3───{python3}
│ └─python3───2*[python3]
I deleted the custom Welcome template via the WebUI (Postorius), and
checked it was removed from the database (PostGres mailman.template).
Then, as site-owner, creating a new custom Welcome template (again via
the WebUI) I can see it correctly added to the database in
mailman.template.uri
-
https://lists.mydomain.com/mailman3/api/templates/list/lists.mydomain.com/l…
Previously it was writing ...
-
http://localhost:8000/mailman3/api/templates/list/lists.mydomain.com/list:u…
So far so good. Nothing showing in mailmanweb.log yet.
Then, still as site-owner using Postorius, I mass-subscribed a new
member (pre confirm, pre approve, pre verify all ticked).
The error below displays on the webpage, the member is subscribed, but
no custom welcome message emailed out.
===================================
HTTP Error 400: HTTPSConnectionPool(host='lists.mydomain.com',
port=443): Read timed out. (read timeout=5)
===================================
And the syslog shows a ton of issues, starting with:
===================================
2024-04-22T23:39:27.536002+00:00 lists mailman[1317]: Apr 22 23:39:27
2024 (1317) HTTPSConnectionPool(host='<LISTS.MYDOMAIN.COM>', port=443):
Read timed out. (read timeout=5)
2024-04-22T23:39:27.537648+00:00 lists mailman[1317]: Traceback (most
recent call last):
2024-04-22T23:39:27.537681+00:00 lists mailman[1317]: File
"/opt/mailman/venv/lib/python3.11/site-packages/urllib3/connectionpool.py",
line 536, in _make_request
2024-04-22T23:39:27.537700+00:00 lists mailman[1317]: response =
conn.getresponse()
2024-04-22T23:39:27.537717+00:00 lists mailman[1317]:
^^^^^^^^^^^^^^^^^^
2024-04-22T23:39:27.537740+00:00 lists mailman[1317]: File
"/opt/mailman/venv/lib/python3.11/site-packages/urllib3/connection.py",
line 461, in getresponse
2024-04-22T23:39:27.537757+00:00 lists mailman[1317]:
httplib_response = super().getresponse()
2024-04-22T23:39:27.537772+00:00 lists mailman[1317]:
^^^^^^^^^^^^^^^^^^^^^
2024-04-22T23:39:27.537790+00:00 lists mailman[1317]: File
"/usr/lib/python3.11/http/client.py", line 1374, in getresponse
===================================
I removed the custom welcome message and the newly subscribed members.
The default "You've been unsubscribed" notice got emailed out okay.
Then mass subscribing a member, the default welcome message gets emailed
out okay and no error displayed on the webpage.
I have no idea what the report in syslog is saying, or where to look
next. Any help appreciated.
1 year, 2 months

[MM3-users] Re: Mails are stuck in Mailman Pipeline Queue
by Shashikanth Komandoor
Thank you Mark for your response.
As you have listed all the runners are shown working fine.
I don't find any traceback during mailman service starting.
But the below trace back is observed during mailman service stopping:
Mar 27 09:01:19 2022 (5859) out runner caught SIGTERM. Stopping.
Mar 27 09:01:19 2022 (5859) out runner exiting.
Mar 27 09:01:19 2022 (5860) pipeline runner caught SIGTERM. Stopping.
Mar 27 09:01:19 2022 (5864) digest runner caught SIGTERM. Stopping.
Mar 27 09:01:19 2022 (5846) Master watcher caught SIGTERM. Exiting.
Mar 27 09:01:19 2022 (5858) nntp runner caught SIGTERM. Stopping.
Mar 27 09:01:19 2022 (5853) archive runner caught SIGTERM. Stopping.
Mar 27 09:01:19 2022 (5858) nntp runner exiting.
Mar 27 09:01:19 2022 (5853) archive runner exiting.
Mar 27 09:01:19 2022 (5854) bounces runner caught SIGTERM. Stopping.
Mar 27 09:01:19 2022 (5854) bounces runner exiting.
Mar 27 09:01:19 2022 (5855) command runner caught SIGTERM. Stopping.
Mar 27 09:01:19 2022 (5855) command runner exiting.
Mar 27 09:01:19 2022 (5863) virgin runner caught SIGTERM. Stopping.
Mar 27 09:01:19 2022 (5863) virgin runner exiting.
Mar 27 09:01:19 2022 (5862) retry runner caught SIGTERM. Stopping.
Mar 27 09:01:19 2022 (5862) retry runner exiting.
Mar 27 09:01:19 2022 (5857) lmtp runner caught SIGTERM. Stopping.
Mar 27 09:01:19 2022 (5857) lmtp runner exiting.
Mar 27 09:01:19 2022 (5856) in runner caught SIGTERM. Stopping.
Mar 27 09:01:19 2022 (5856) in runner exiting.
[2022-03-27 09:01:19 +0530] [5861] [INFO] Handling signal: term
[2022-03-27 09:01:19 +0530] [18009] [INFO] Worker exiting (pid: 18009)
[2022-03-27 09:01:19 +0530] [18004] [INFO] Worker exiting (pid: 18004)
[2022-03-27 09:01:21 +0530] [5861] [INFO] Shutting down: Master
Mar 27 09:01:22 2022 (5864) Uncaught runner exception:
Mar 27 09:01:22 2022 (5864) Traceback (most recent call last):
File "/var/lib/mailman/venv/lib64/python3.6/site-packages/mailman/core/runner.py",
line 173, in _one_iteration
self._process_one_file(msg, msgdata)
File "/var/lib/mailman/venv/lib64/python3.6/site-packages/mailman/core/runner.py",
line 266, in _process_one_file
keepqueued = self._dispose(mlist, msg, msgdata)
File "/var/lib/mailman/venv/lib64/python3.6/site-packages/mailman/runners/digest.py",
line 332, in _dispose
digest_members = set(mlist.digest_members.members)
File "/var/lib/mailman/venv/lib64/python3.6/site-packages/mailman/model/roster.py",
line 254, in members
DeliveryMode.summary_digests)
File "/var/lib/mailman/venv/lib64/python3.6/site-packages/mailman/model/roster.py",
line 226, in _get_members
if member.delivery_mode in delivery_modes:
File "/var/lib/mailman/venv/lib64/python3.6/site-packages/mailman/model/member.py",
line 205, in delivery_mode
return self._lookup('delivery_mode')
File "/var/lib/mailman/venv/lib64/python3.6/site-packages/mailman/model/member.py",
line 167, in _lookup
pref = getattr(self.address.preferences, preference)
File "/var/lib/mailman/venv/lib64/python3.6/site-packages/mailman/model/member.py",
line 117, in address
if self._address is None
File "/var/lib/mailman/venv/lib64/python3.6/site-packages/sqlalchemy/orm/attributes.py",
line 287, in __get__
return self.impl.get(instance_state(instance), dict_)
File "/var/lib/mailman/venv/lib64/python3.6/site-packages/sqlalchemy/orm/attributes.py",
line 723, in get
value = self.callable_(state, passive)
File "/var/lib/mailman/venv/lib64/python3.6/site-packages/sqlalchemy/orm/strategies.py",
line 760, in _load_for_state
session, state, primary_key_identity, passive
File "/var/lib/mailman/venv/lib64/python3.6/site-packages/mailman/core/runner.py",
line 114, in signal_handler
raise RunnerInterrupt
mailman.interfaces.runner.RunnerInterrupt
Mar 27 09:01:22 2022 (5864) SHUNTING: 1648351882.6693938+
c2e6ed709646a7680c73059b52d2f0451836e591
Mar 27 09:01:22 2022 (5864) digest runner exiting.
Mar 27 09:01:22 2022 (5860) Uncaught runner exception:
Mar 27 09:01:22 2022 (5860) Traceback (most recent call last):
File "/var/lib/mailman/venv/lib64/python3.6/site-packages/mailman/core/runner.py",
line 173, in _one_iteration
self._process_one_file(msg, msgdata)
File "/var/lib/mailman/venv/lib64/python3.6/site-packages/mailman/core/runner.py",
line 266, in _process_one_file
keepqueued = self._dispose(mlist, msg, msgdata)
File "/var/lib/mailman/venv/lib64/python3.6/site-packages/mailman/runners/pipeline.py",
line 37, in _dispose
process(mlist, msg, msgdata, pipeline)
File "/var/lib/mailman/venv/lib64/python3.6/site-packages/mailman/core/pipelines.py",
line 50, in process
handler.process(mlist, msg, msgdata)
File "/var/lib/mailman/venv/lib64/python3.6/site-packages/
mailman/handlers/member_recipients.py", line 84, in process
for member in mlist.regular_members.members
File "/var/lib/mailman/venv/lib64/python3.6/site-packages/
mailman/handlers/member_recipients.py", line 83, in <genexpr>
recipients = set(member.address.email
File "/var/lib/mailman/venv/lib64/python3.6/site-packages/mailman/model/roster.py",
line 239, in members
yield from self._get_members(DeliveryMode.regular)
File "/var/lib/mailman/venv/lib64/python3.6/site-packages/mailman/model/roster.py",
line 226, in _get_members
if member.delivery_mode in delivery_modes:
File "/var/lib/mailman/venv/lib64/python3.6/site-packages/mailman/model/member.py",
line 205, in delivery_mode
return self._lookup('delivery_mode')
File "/var/lib/mailman/venv/lib64/python3.6/site-packages/mailman/model/member.py",
line 167, in _lookup
pref = getattr(self.address.preferences, preference)
File "/var/lib/mailman/venv/lib64/python3.6/site-packages/sqlalchemy/orm/attributes.py",
line 287, in __get__
return self.impl.get(instance_state(instance), dict_)
File "/var/lib/mailman/venv/lib64/python3.6/site-packages/sqlalchemy/orm/attributes.py",
line 723, in get
value = self.callable_(state, passive)
File "/var/lib/mailman/venv/lib64/python3.6/site-packages/sqlalchemy/orm/strategies.py",
line 760, in _load_for_state
session, state, primary_key_identity, passive
File "<string>", line 1, in <lambda>
File "/var/lib/mailman/venv/lib64/python3.6/site-packages/sqlalchemy/orm/strategies.py",
line 850, in _emit_lazyload
session.query(self.mapper), primary_key_identity
File "/var/lib/mailman/venv/lib64/python3.6/site-packages/sqlalchemy/ext/baked.py",
line 603, in _load_on_pk_identity
setup, tuple(elem is None for elem in primary_key_identity)
File "/var/lib/mailman/venv/lib64/python3.6/site-packages/mailman/core/runner.py",
line 114, in signal_handler
raise RunnerInterrupt
mailman.interfaces.runner.RunnerInterrupt
Mar 27 09:01:22 2022 (5860) SHUNTING: 1648351882.8537986+
9bf59cb23a71a4bae65536bfdbec0abb261adaa0
Mar 27 09:01:22 2022 (5860) pipeline runner exiting.
Mar 27 09:01:23 2022 (5846) Master stopped
I have shared more log because I could not understand where can the clue be
to resolve the issue. Please suggest me.
On Sat, Mar 26, 2022, 11:33 PM Mark Sapiro <mark(a)msapiro.net> wrote:
> On 3/26/22 10:28, Shashikanth Komandoor wrote:
> > Hi Team,
> >
> > We have restarted the services as well but no change.
>
>
> Odd.
>
>
> > We tried manually moving the pck file from pipeline queue to
> > out queue but the file disappeared from out queue but is not getting
> > delivered.
>
>
> This is expected because if the message hasn't been processed through
> the pipeline, it has no recipients in the metadata, so the outgoing
> runner delivered it to no one. Also, it skipped archiving and digesting.
>
> > We moved the pck file from pipeline queue to out queue with
> the
> > extension .bak still no use.
>
>
> Same as above.
>
>
> > Not sure what to try next. Please help.
>
>
> Mi first guess is the pipeline runner isn't running, but you restarted
> the services, presumably Mailman core, and that might fix it, but there
> are various ways the pipeline runner could have died that would cause
> the master to not restart it.
>
> You need to stop Mailman core and then start it rather than just
> restarting. That may help.
>
> Also look in mailman.log. Assuming the pipeline runner died at some
> point, there should be a log entry and possible an exception with
> traceback indicating why.
>
> You can see which runners are running with something like
> ```
> ps -fwwA|grep runner=|sed s/.*runner=//
> ```
> This should produce a list something like
> ```
> archive:0:1
> bounces:0:1
> command:0:1
> in:0:1
> lmtp:0:1
> nntp:0:1
> out:0:1
> pipeline:0:1
> rest:0:1
> retry:0:1
> task:0:1
> virgin:0:1
> digest:0:1
> rest:0:1
> rest:0:1
> ```
> except depending on version, `task` may not be there.
>
>
> --
> Mark Sapiro <mark(a)msapiro.net> The highway is for gamblers,
> San Francisco Bay Area, California better use your sense - B. Dylan
> _______________________________________________
> Mailman-users mailing list -- mailman-users(a)mailman3.org
> To unsubscribe send an email to mailman-users-leave(a)mailman3.org
> https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/
>
3 years, 3 months

[MM3-users] Re: Confirm and Moderate Unsubscribe Requests
by Brian Carpenter
On 10/21/20 9:39 PM, Abhilash Raj wrote:
>
> On Wed, Oct 21, 2020, at 3:35 PM, Brian Carpenter wrote:
>> On 10/21/20 5:39 PM, Mark Sapiro wrote:
>>> On 10/21/20 12:14 PM, Brian Carpenter wrote:
>>>> Well I can't dictate that to my list owners and there is no confirm
>>>> token sent with the moderation notice. Why include this option in
>>>> Postorius when it can't be properly handled?
>>> Postorius is still a work in progress. The unsubscription policies are
>>> in core and are exposed in Postorius. Certainly the ability to moderate
>>> an unsubscription should be in Postorius, but it isn't yet. We are an
>>> all volunteer project and there aren't that many of us, and perhaps I'm
>>> overreacting, but the tone of some of your recent posts seems a bit
>>> demanding.
>> I apologize. I didn't think I was coming across demanding but I am
>> somewhat exasperated at some of these issues. I have a list owner who is
>> now going to get a moderated request notice everyday that he can't do
>> anything about it.
>>
>> But my question still remains: why is this option in Postorius when it
>> can't be handled properly? Surely the option can be easily removed, right?
> I added the option in my drive to expose every possible Mailinglist settings via Postorius and missed the fact that we weren't actually able to moderate those requests.
>
> Yes, this option can be hidden if it doesn't work until the next stable release. I hid one of the list settings in Postorius exactly because it didn't work, but this one slipped.
Thank you. I will go ahead and remove the option within Affinity.
>> Is the ability to list (via the pending moderation notices tab) and
>> handle (as in the List owner can decide a moderation response) an
>> unsubscribe moderation request there in Mailman core so that I can
>> properly address it via Affinity?
> Unfortunately no, there is a bug report open for it though and I have some done some analysis on root cause[1]. The bug turned out to be a more than a trivial one and I haven't been able to get to it yet.
>
> [1]: https://gitlab.com/mailman/mailman/-/issues/768
>
>
This is good information to have at least so I appreciate letting me
know. I probably need to spend more time looking through the outstanding
issues for Mailman core and Postorius before launching a nuclear strike
of epic and catastrophic proportions upon Mark.
--
Brian Carpenter
Harmonylists.com
Emwd.com
4 years, 8 months

[MM3-users] Re: Errors while importing mm2 list archives - SOLVED
by Odhiambo Washington
On Thu, Dec 22, 2022 at 9:36 AM Mark Sapiro <mark(a)msapiro.net> wrote:
> On 12/20/22 22:25, Odhiambo Washington wrote:
> >
> > In my case, running `mailman` without any arguments just makes it grok :)
> >
> > (venv) [mailman@gw ~/mm]$ mailman info
> ...
> > *config file: /opt/mailman/mm/mailman.cfg*
>
>
> That's because it first looks in the current directory for `mailman.cfg`
> and only if it doesn't find it there does it look in /etc/mailman3.
>
And that happens because I have all my config files in /opt/mailman/mm/.
So if I moved all of them to /etc/mailman3/ it would settle for that? I
will test it.
>> Ultimately, when I did the import, there was only one email from the
> >>> archives that failed to be imported - which I honestly don't mind, but
> >>> maybe there is a solution for this
> >>> "'utf-8' codec can't encode character '\udcae' in position 331:
> >> surrogates not allowed" ??
> >>
> >>
> >> If you provide a copy of that message from the mbox, either on the list
> >> or to me directly, I'll investigate.
> >>
> >
> > A mbox file containing that email and the associated thread can be
> > downloaded from here:
> > https://webmail.kictanet.or.ke/~wash/chunk_7.txt.gz
>
> The offending message is multipart with an attached message/rfc822 part
> and that part has a preamble which in bytes is
>
> b'This document is a Single File Web Page, also known as a Web Archive
> file. If you are seeing this message, your browser or editor doesn't
> support Web Archive files. Please download a browser that supports Web
> Archive, such as Windows\xae Internet Explorer\xae.'
>
> The '\xae' is an iso-8859-1 encoding for '®', but no charset is
> specified for this preamble so email message parsing ends up decoding
> those as surrogates '\udcae' which throws the exception when
> hyperkitty.lib.incoming.add_to_list() in trying to save the attachment
> does `att.set_content(content)`.
>
> Normally, when messages to be archived arrive from core via
> mailman_hyperkitty, the surrogates are replaced by
> email.utils._sanitize(), but this doesn't happen with messages from
> hyperkitty_import.
>
I am glad it's an email that is probably overtaken by events. However, the
good thing is that I will have the archives from MM2 still accessible once
I move to MM3.
--
Best regards,
Odhiambo WASHINGTON,
Nairobi,KE
+254 7 3200 0004/+254 7 2274 3223
"Oh, the cruft.", egrep -v '^$|^.*#' ¯\_(ツ)_/¯ :-)
2 years, 6 months

[MM3-users] Re: Mailman3 without Hyperkitty in docker
by Abhilash Raj
On Thu, Feb 28, 2019, at 10:18 PM, Danil Smirnov wrote:
> Hi Abhilash,
>
> Thank you very much - the previous error is fixed now.
>
> But I have another one now, which causes the same 500 Server Error:
>
> bash-4.3# cat /opt/mailman-web-data/logs/uwsgi-error.log
> *** Starting uWSGI 2.0.18 (64bit) on [Fri Mar 1 05:42:09 2019] ***
> compiled with version: 6.3.0 on 01 March 2019 01:52:42
> os: Linux-3.10.0-693.11.1.el7.x86_64 #1 SMP Mon Dec 4 23:52:40 UTC 2017
> nodename: mailman-web
> machine: x86_64
> clock source: unix
> detected number of CPU cores: 2
> current working directory: /opt/mailman-web
> detected binary path: /usr/local/bin/uwsgi
> !!! no internal routing support, rebuild with pcre support !!!
> setgid() to 101
> setuid() to 100
> chdir() to /opt/mailman-web
> your memory page size is 4096 bytes
> detected max file descriptor number: 1048576
> building mime-types dictionary from file /etc/mime.types...1168 entry found
> lock engine: pthread robust mutexes
> thunder lock: disabled (you can enable it with --thunder-lock)
> uwsgi socket 0 bound to TCP address 0.0.0.0:8080 fd 8
> uwsgi socket 1 bound to TCP address 0.0.0.0:8000 fd 9
> Python version: 3.6.8 (default, Jan 30 2019, 23:58:16) [GCC 6.3.0]
> Python main interpreter initialized at 0x55a2df7f57e0
> python threads support enabled
> your server socket listen backlog is limited to 100 connections
> your mercy for graceful operations on workers is 60 seconds
> mapped 166752 bytes (162 KB) for 2 cores
> *** Operational MODE: threaded ***
> Traceback (most recent call last):
> File "/usr/local/lib/python3.6/site-packages/django/utils/module_loading.py", line 20, in import_string
> return getattr(module, class_name)
> AttributeError: module 'django.contrib.auth.middleware' has no attribute 'SessionAuthenticationMiddleware'
>
> The above exception was the direct cause of the following exception:
>
> Traceback (most recent call last):
> File "wsgi.py", line 38, in <module>
> application = get_wsgi_application()
> File "/usr/local/lib/python3.6/site-packages/django/core/wsgi.py", line 13, in get_wsgi_application
> return WSGIHandler()
> File "/usr/local/lib/python3.6/site-packages/django/core/handlers/wsgi.py", line 136, in __init__
> self.load_middleware()
> File "/usr/local/lib/python3.6/site-packages/django/core/handlers/base.py", line 34, in load_middleware
> middleware = import_string(middleware_path)
> File "/usr/local/lib/python3.6/site-packages/django/utils/module_loading.py", line 24, in import_string
> ) from err
> ImportError: Module "django.contrib.auth.middleware" does not define a "SessionAuthenticationMiddleware" attribute/class
> unable to load app 0 (mountpoint='') (callable not found or import error)
> *** no app loaded. going in full dynamic mode ***
> *** uWSGI is running in multiple interpreter mode ***
> spawned uWSGI master process (pid: 1)
> spawned uWSGI worker 1 (pid: 37, cores: 2)
> --- no python application found, check your startup logs for errors ---
> --- no python application found, check your startup logs for errors ---
> --- no python application found, check your startup logs for errors ---
> --- no python application found, check your startup logs for errors ---
> --- no python application found, check your startup logs for errors ---
> --- no python application found, check your startup logs for errors ---
> --- no python application found, check your startup logs for errors ---
> --- no python application found, check your startup logs for errors ---
> --- no python application found, check your startup logs for errors ---
> --- no python application found, check your startup logs for errors ---
> --- no python application found, check your startup logs for errors ---
> --- no python application found, check your startup logs for errors ---
>
> As per my investigation, this error possibly caused by Django upgrade:
>
> *The SessionAuthenticationMiddleware class is removed. It provided no functionality since session authentication is unconditionally enabled in Django 1.10.*
>
> See https://docs.djangoproject.com/en/2.0/releases/2.0/
>
> After I've removed the line
> https://github.com/maxking/docker-mailman/blob/master/postorius/mailman-web…
> from settings.py, the container is finally working.
>
> I've placed PR in github:
> https://github.com/maxking/docker-mailman/pull/314
Thank you for your contributions!
I have merged your pull request and it should now be out (hopefully!).
>
> Thank you for your help.
>
> Danil
>
>
> пт, 1 мар. 2019 г. в 04:33, Abhilash Raj <maxking(a)asynchronous.in>:
>>
>>
>> On Thu, Feb 28, 2019, at 5:19 PM, Abhilash Raj wrote:
>> > On February 27, 2019 11:53:34 PM PST, Danil Smirnov <danil(a)smirnov.la> wrote:
>> > >Hi Mark,
>> > >
>> > >Actually all this stuff happens inside the container after it's started
>> > >and
>> > >initialized without errors. I didn't amend the image anyhow.
>> > >
>> > >Also I have the configuration based on docker-compose.yaml provided in
>> > >the
>> > >repository which works just fine for mailman-web image.
>> > >
>> > >The very same config with postorius image (+ UWSGI_STATIC_MAP param)
>> > >fails
>> > >with 500 error...
>> > >
>> > >Now answering your questions:
>> > >
>> > >ср, 27 февр. 2019 г., 22:56 Mark Sapiro <mark(a)msapiro.net>:
>> > >
>> > >> do you have django-q in INSTALLED_APPS in your Django settings and
>> > >what
>> > >> is set for Q_CLUSTER?
>> > >>
>> > >
>> > >I've checked settings.py inside the container and I haven't found any
>> > >of
>> > >the mentioned configurations there.
>> > >
>> > >Does the manage.py that's being run here point to the right
>> > >settings.py?
>> > >>
>> > >
>> > >No clue.
>> > >
>> > >Also I wonder why we have some Hyperkitty-related cronjobs in non-HK
>> > >configured image?
>> > >
>> > >https://github.com/maxking/docker-mailman/blob/master/postorius/mailman-web…
>> >
>> > Because I am a dum dum ;-)
>> >
>> > Will work on removing those crons and stuff. Would be nice if you
>> > opened an issue on Github so that I don't forget.
>>
>> Should now be fixed in the latest image.
>>
>> >
>> > >Danil
>> > >
>> > >
>> > >
>> > >> --
>> > >> Mark Sapiro <mark(a)msapiro.net> The highway is for gamblers,
>> > >> San Francisco Bay Area, California better use your sense - B.
>> > >Dylan
>> > >> _______________________________________________
>> > >> Mailman-users mailing list -- mailman-users(a)mailman3.org
>> > >> To unsubscribe send an email to mailman-users-leave(a)mailman3.org
>> > >> https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/
>> > >>
>> > >_______________________________________________
>> > >Mailman-users mailing list -- mailman-users(a)mailman3.org
>> > >To unsubscribe send an email to mailman-users-leave(a)mailman3.org
>> > >https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/
>> >
>> >
>> > --
>> > Sent from my Android device with K-9 Mail. Please excuse my brevity.
>>
>> --
>> thanks,
>> Abhilash Raj (maxking)
--
thanks,
Abhilash Raj (maxking)
6 years, 4 months

[MM3-users] re-sending confirmation mails (was Re: Re: pending subscriptions lost?)
by IEM Network Operation Center (IOhannes m zmölnig)
On 3/14/22 18:36, Mark Sapiro wrote:
> On 3/14/22 09:18, IEM Network Operation Center (IOhannes m zmölnig) wrote:
>>
>> this is with "Postorius Version 1.2.4" (as installed by the mailman3
>> Debian package).
>
> The Debian packages are OK for people who want to install things via a
> package manager, but they are quite out of date.
i know.
the problem is, that right now i have a running (Debian-based, thus
outdated) mailman3 installation, and I still haven't found a proper
strategy to upgrade and keep staying up-to-date.
so for the time being i'm stuck with what i have.
>
> Something like the following in `mailman shell` can do it.
thanks a lot.
afaiu, this snippet allows me to purge outdated pending subscriptions.
modifying it slightly, also allows me to just list the pending
subscriptions along with their tokens and print them out.
is it still possible to just use these tokens to confirm the pending
subscription (even though it is long overdue)?
if so, i could just send out a reminder to those 50 or so people who
have not confirmed yet.
while investigating this a bit, i also noticed that it seems that with
mailman3 the only option to confirm a pending subscription is via email
("leaving the subject intact") - at least that is the only option that
is listed in the confirmation mail.
now i would like to massage this into what i think is a bit more
user-friendly.
first of all: most email confirmation systems allow me to either "reply
by email" or "click this link".
is there a way to do this for mailman3? that is: is there a (hidden) URL
that would accept the token in order to confirm a subscription?
also: the confirmation mail says that the subject must be kept intact.
however, i noticed that the actual "From" address of the confirmation
mail already contains the token.
would it be enough if people just sent an email to this special
email-address (that contains the token), regardless of the subject?
i'm thinking of sending a rather personalized email that has a more
attractive subject than "confirm flkdsajfsalkjflsajfsoisjdl".
finally: what else is required to approve the confirmation? will the
sender's email-address be taken into account? (e.g. if they subscribed
"foo+mylist(a)example.com" but send the confirmation-reply from
"foo(a)example.com", will that still work?
sorry for so many questions.
i *did* search the documentation, but simply haven't found anything that
would help me.
i've probably looked in the wrong places, but mailman3 is rather huge so
it's easy to miss the imprtant parts.
gmdsa
IOhannes
3 years, 3 months

[MM3-users]Re: mailman 2 vs. mailman 3: what happened to multipart/digest?
by John Hein
Mark Sapiro wrote at 12:18 -0700 on May 12, 2016:
> On 5/12/16 9:16 AM, deu8yz2mpq(a)snkmail.com wrote:
> > Digest delivery in mailman 2 encapsulated the individual message/rfc822 messages in a multipart/digest container. This allowed email clients to show the messages in the particular digest in a threaded view.
>
>
> This format vs. plain text digests was a user option in Mailman 2.
>
>
> > It seems like the various digest options that I have tried [1] in mailman 3.1.0 (as implemented for the fedora-users mailing list) no longer encapsulate messages in multipart/digest.
>
>
> The core still supports the same plain text and MIME format digests and
> the same individual subscriber and per-list default formats as did
> Mailman 2. The issue is none of these things are exposed in Postorius.
>
> If you subscribe to digests on this list, you will receive the
> 'encapsulated' MIME format because the lists mime_is_default_digest
> setting is True, but currently that has to be set through the
> bin/mailman shell tool.
>
>
> > Is this intentional? Is it a bug - feature that was lost in translation from 2 to 3? Is there a delivery option I'm missing that will turn that back on?
Thanks for the info - and Barry's reply as well. I understand that
MIME digests are supported in Mailman 3 - that's what I'm using (and
thanks, Barry, for the info that Summary Digests is the same right
now). My quibble is that the multipart/digest encapsulation level is
gone.
Barry Warsaw wrote at 15:16 -0400 on May 12, 2016:
> The MIME format of MIME digests should roughly be:
>
> multipart/mixed
> text/plain (the digest heading)
> text/plain (the TOC)
> message/rfc822
> message-1
> message/rfc822
> message-2
> ...
> text/plain (footer)
But mm 2 had:
multipart/mixed
text/plain (the digest heading)
text/plain (the TOC)
multipart/digest <--- this is the part that's gone in mm3
message/rfc822
message-1
message/rfc822
message-2
...
text/plain (footer)
So was that removal intentional, a bug or ??
Maybe you're saying there is definitely an unexposed (in Postorius)
knob for that in mm3.
>
> It is the intent that Postorius will eventually expose all these
> settings. We're not there yet. At present you could possibly do this by
> interacting with mailmanclient, although I'm not certain the settings
> are exposed there. You can do it via bin/mailman shell if you have
> access and know what you're doing (see
> <http://mailman.readthedocs.io/en/release-3.0/src/mailman/runners/docs/diges…>)
>
> If you file an issue at
> <https://gitlab.com/mailman/postorius/issues/new>, it might help
> expedite this.
Okay.
9 years, 1 month

[MM3-users] Re: Customise Postorius templates?
by Duane Raymond
On Mon, 7 Feb 2022 at 00:56, Abhilash Raj <maxking(a)asynchronous.in> wrote:
> > On Feb 1, 2022, at 11:01 AM, Mark Sapiro <mark(a)msapiro.net> wrote:
> >
> > On 2/1/22 09:47, Duane Raymond wrote:
> >> Hi,
> >> I'm looking to do some radical customisation of the Postorius (and
> Hyperkitty) templates over the next 6 ish months and was wondering if there
> is a 'best practice' way to do this that will survive updates to MM3. I've
> searched around and not found much and also tested copying
> >>
> venv/lib/python3.7/site-packages/postorius/templates/postorius/lists/summary.html
> >> to
> >> var/templates/lists/summary.html
> >> As suggested in some posts - but it didn't seem to pick up the
> customisation - only customisations in the venv path worked - and they get
> overwritten on update.
> The best way to do this would be utilize Django’s template loader. See
> here[1] for the documentation on how you can do this. You want to put the
> path where you are putting the templates under `DIRS` option of the
> `TEMPLATES` section.
>
> Do make sure that you are keeping the directory structure correct so that
> Django can discover them. Like, Hyperkitty’s base.html should be in
> `/custom/path/hyperkitty/base.html`, where `/custom/path` is what you’ve
> setup in DIRS setting above.
>
This looks promising! I've not got it working yet, but this is what I've
tried:
1. Created folder 'custom' in the mm root (in my case: /opt/mailman/mm/)
2. Copied the files and folders from postorius/templates/postorius/* and
hyperkitty/templates/hyperkitty/* to the custom/ folder (not the
full postorius/templates/postorius/ match, just evening in the
second postorius/ dirrectory)
3. Recursive update of permissions of the custom/ folder and files to be
mailman
4. Updated /opt/mailman/mm/settings.py by changing "'DIRS': []"
to "'DIRS': [BASE_DIR, '/custom/']" in the "TEMPLATES =" section
5. Edited the original AND copied postorius/lists/summary.html to have a
small change in the footer of each so I know what version it is serving
6. Restarted: gunicorn qcluster mailman nginx and cleared browser cache
7. Reloaded the 'info' page of a few lists to see which version ti was
serving
Variants: I've also changed the DIRS value to the hard-coded path:
/opt/mailman/mm/custom
Result: it is still serving the default/original Postorius template vs the
custom one.
Any suggestions for things I should do to make it use the /custom/ folder
instead? Any recompiling or other actions beyond just restarting? (I
probably don't need to restart qcluster and maybe not even mailman core for
this to take effect but I do it just in case!)
Cheers,
Duane
3 years, 4 months

[MM3-users] Re: Hyperkitty on Debian 12
by Markus Grandpre
Dear Michael,
thank you very much for your clarification.
Best regards,
Markus
Am 3/26/24 um 17:38 schrieb Michael Oberrauch:
> On Tue, 2024-03-26 at 08:06 +0100, Markus Grandpré wrote:
>> Dear Mr Sapiro,
>>
>> thank you very much for your help. The required command is:
>>
>> # mailman-web hyperkitty_import \
>> -l mailman21-migration-test-04(a)mailman.uni-konstanz.de \
>> /var/mailman21/testlist.mbox
>>
>> Due to the following warnings, I still have to customize Hyperkitty:
>>
>> django_mailman3.MailDomain: (models.W042) Auto-created primary key
>> used
>> when not defining a primary key type, by default
>> 'django.db.models.AutoField'.
>> HINT: Configure the DEFAULT_AUTO_FIELD setting or the
>> DjangoMailman3Config.default_auto_field attribute to point to a
>> subclass
>> of AutoField, e.g. 'django.db.models.BigAutoField'.
>> ...
>>
>> Can you give me another hint? As Linux admin I installed the packages
>> mailman and mailman-web that were offered to me under Debian 12.
>> Although during the installation of the packages user "list" was
>> created, I cannot use it:
>>
>> # su - list
>> This account is currently not available
>>
>> As with Mailman 2.1, I will probably have to continue working with
>> Mailman3 as root. Too bad that there is no documentation for Debian
>> admins like me, who don't want to dive too deep into the python
>> framework. Or have I overlooked something?
>>
>> Best regards,
>> Markus
>>
>>
>
> Hi Markus,
>
> we are also running MM3 on Debian 12 from Package Repositories.
>
> First of all, you should not try to directly switch user (su) to the
> lists user, it's generally intended to executes commands as that user,
> if necessary; either using `runuser`, `sudo`, or `su -c`.
>
> However, the prepackaged scripts `mailman-wrapper` and `mailman-web`
> already do this and therefore you ca run those as root without
> permission problems.
>
> On Debian there are two relevant users for MM3: the list user runs
> mailman core, whereas the www-data user runs Postorius and Hyperkitty.
> So you have to make shure, that the www-data user can access the .mbox
> files while importing.
>
> Hope that helps.
>
> Cheers,
> Michael
>
>
>
> _______________________________________________
> Mailman-users mailing list -- mailman-users(a)mailman3.org
> To unsubscribe send an email to mailman-users-leave(a)mailman3.org
> https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/
> Archived at: https://lists.mailman3.org/archives/list/mailman-users@mailman3.org/message…
>
> This message sent to markus.grandpre(a)uni-konstanz.de
--
Markus Grandpré
Universität Konstanz
Kommunikations-, Informations-, Medienzentrum (KIM)
Abteilung IT-Dienste Forschung, Lehre und Infrastruktur,
Tel: ++49 7531 88 4342
1 year, 3 months

[MM3-users] Re: mail loops back to myself
by Florian Sukup
On 6/12/25 05:08, Mark Sapiro wrote:
> On 6/11/25 13:51, Florian Sukup wrote:
>> I have now elimiated reverse.rrr.com. But there isn't much change:
>>
>> vvvvvvvvvvvvvvvvvvvvvvvvv
>> Jun 11 22:19:57 arvak postfix/relay/smtp[1015580]: initializing the
>> client-side TLS engine
>> Jun 11 22:19:57 arvak postfix/smtpd[1015581]: initializing the
>> server-side TLS engine
>> Jun 11 22:19:57 arvak postfix/smtpd[1015581]: connect from
>> host.xxx.com[m.y.i.p]
>> Jun 11 22:19:57 arvak postfix/relay/smtp[1015580]: warning: host
>> host.xxx.com[m.y.i.p]:25 greeted me with my own hostname host.xxx.com
>> Jun 11 22:19:57 arvak postfix/relay/smtp[1015580]: warning: host
>> host.xxx.com[m.y.i.p]:25 replied to HELO/EHLO with my own hostname
>> host.xxx.com
>> Jun 11 22:19:57 arvak postfix/relay/smtp[1015580]: 29FCF5F867:
>> to=<mylists(a)lists.yyy.com>, relay=host.xxx.com[m.y.i.p]:25, delay=0.2,
>> delays=0.06/0.01/0.13/0, dsn=5.4.6, status=bounced (mail for
>> lists.yyy.com loops back to myself)
>> Jun 11 22:19:57 arvak postfix/smtpd[1015581]: disconnect from
>> host.xxx.com[m.y.i.p] ehlo=1 quit=1 commands=2
>
>
> I think you need to add host.xxx.com to mydestinations.
>
I did that now but no change.
When I look into the log, first the smtpd receives the message from my
mail client. Then the email is queued.
And then the smtp initiates a TLS layer to send it to the smtpd on the
same machine. For my understanding this cannot be correct. The smtpd at
first should hand it to mailman and not relay it to itself. Is that correct?
Here is the complete log up to the point when the error email is created:
vvvvvvvvvvvvvvvvvvvvvvvvvvvv
Jun 12 12:22:24 arvak postfix/smtpd[1197617]: connect from
host.xxx.com[192.168.77.100]
Jun 12 12:22:24 arvak postfix/smtpd[1197617]: 53E665F8D2:
client=host.xxx.com[192.168.77.100]
Jun 12 12:22:24 arvak postfix/cleanup[1197827]: 53E665F8D2:
message-id=<35c8a748-b410-46a6-91fc-5cee9f31fc39(a)email.addr>
Jun 12 12:22:24 arvak postfix/qmgr[1147234]: 53E665F8D2:
from=<my(a)email.addr>, size=598, nrcpt=1 (queue active)
Jun 12 12:22:24 arvak postfix/relay/smtp[1197829]: initializing the
client-side TLS engine
Jun 12 12:22:24 arvak postfix/smtpd[1197830]: initializing the
server-side TLS engine
Jun 12 12:22:24 arvak postfix/smtpd[1197830]: connect from
host.xxx.com[m.y.i.p]
Jun 12 12:22:24 arvak postfix/relay/smtp[1197829]: warning: host
host.xxx.com[m.y.i.p]:25 greeted me with my own hostname host.xxx.com
Jun 12 12:22:24 arvak postfix/relay/smtp[1197829]: warning: host
host.xxx.com[m.y.i.p]:25 replied to HELO/EHLO with my own hostname
host.xxx.com
Jun 12 12:22:24 arvak postfix/relay/smtp[1197829]: 53E665F8D2:
to=<mylists(a)lists.yyy.com>, relay=host.xxx.com[m.y.i.p]:25, delay=0.31,
delays=0.12/0.01/0.18/0, dsn=5.4.6, status=bounced (mail for
lists.yyy.com loops back to myself)
Jun 12 12:22:24 arvak postfix/smtpd[1197830]: disconnect from
host.xxx.com[m.y.i.p] ehlo=1 quit=1 commands=2
2 weeks, 6 days

[MM3-users] Re: Newbie question 2: Rewriting issue for bounced emails
by William Oliver
On Sun, 2021-12-26 at 18:23 -0800, Mark Sapiro wrote:
> On 12/26/21 6:19 PM, Mark Sapiro wrote:
> >
> > Otherwise, you can do this in mailman shell, e.g.
> > ```
> > $ mailman shell
> >
> > Welcome to the GNU Mailman shell
> > Use commit() to commit changes.
> > Use abort() to discard changes since the last commit.
> > Exit with ctrl+D does an implicit commit() but exit() does not.
> >
> > >>> dm = getUtility(IDomainManager)
> > >>> d = dm.get('example.com')
> > >>> d.alias_domain = x.example.com
> > >>> commit()
> > ```
>
>
> Ooops. That should be
>
> d.alias_domain = 'x.example.com'
>
> I.e., quoted
>
>
Thanks. I am *almost* there. Adding the vmap in mailman fixed *almost*
everything. Now I can add users, get receive mails to the list, archive
messages correctly, and send emails. Except...
The list sends emails to local recipients fine. I have three users on
my test list:
fp145(a)libertyfp.org (local)
billo(a)billoblog.com (not local)
oliver(a)billoblog.com (not local)
When I send a message to the list from *any* of these three, the
mailman3 accepts it and attempts to broadcast it out. It is delivered
sucessfully to the local email address, but it looks like there's a
relaying problem with external addresses.
In the syslog snippet below, note that the fp145(a)libertyfp.org mail is
delivered, but the mail to the recipients at billoblog.com get an
"Access denied"
Dec 27 15:33:25 libertyfp postfix/smtpd[419593]: connect from
mail.libertyfp.org[2.56.57.28]
Dec 27 15:33:25 libertyfp postfix/smtpd[419593]: DC203421BE:
client=mail.libertyfp.org[2.56.57.28]
Dec 27 15:33:25 libertyfp postfix/cleanup[420001]: DC203421BE: message-
id=<9785b5a56581104fe079221bb947eb3a03813d97.camel(a)billoblog.com>
Here it is getting delivered locally:
Dec 27 15:33:25 libertyfp postfix/cleanup[420001]: DC203421BE: warning:
header Subject: [Testlist] bbbbb from mail.libertyfp.org[2.56.57.28];
from=<testlist-bounces+fp145=libertyfp.org(a)libertyfp.org>
to=<fp145(a)libertyfp.org> proto=ESMTP helo=<mail.libertyfp.org>
Dec 27 15:33:25 libertyfp postfix/qmgr[418758]: DC203421BE:
from=<testlist-bounces+fp145=libertyfp.org(a)libertyfp.org>, size=2651,
nrcpt=1 (queue active)
Dec 27 15:33:25 libertyfp postfix/virtual[420016]: DC203421BE:
to=<fp145(a)libertyfp.org>, relay=virtual, delay=0.03,
delays=0.01/0.01/0/0.01, dsn=2.0.0, status=sent (delivered to maildir)
Dec 27 15:33:25 libertyfp postfix/qmgr[418758]: DC203421BE: removed
Here it is getting bounced for billo(a)billoblog.com and
oliver(a)billoblog.com:
Dec 27 15:33:26 libertyfp postfix/smtpd[419593]: NOQUEUE: reject: RCPT
from mail.libertyfp.org[2.56.57.28]: 554 5.7.1 <billo(a)billoblog.com>:
Recipient address rejected: Access denied;
from=<testlist-bounces+billo=billoblog.com(a)libertyfp.org>
to=<billo(a)billoblog.com> proto=ESMTP helo=<mail.libertyfp.org>
Dec 27 15:33:26 libertyfp postfix/smtpd[419593]: disconnect from
mail.libertyfp.org[2.56.57.28] ehlo=1 mail=2 rcpt=1/2 data=1 rset=1
quit=1 commands=7/8
Dec 27 15:33:26 libertyfp postfix/smtpd[419593]: connect from
mail.libertyfp.org[2.56.57.28]
Dec 27 15:33:26 libertyfp postfix/smtpd[419593]: NOQUEUE: reject: RCPT
from mail.libertyfp.org[2.56.57.28]: 554 5.7.1 <oliver(a)billoblog.com>:
Recipient address rejected: Access denied;
from=<testlist-bounces+oliver=billoblog.com(a)libertyfp.org>
to=<oliver(a)billoblog.com> proto=ESMTP helo=<mail.libertyfp.org>
This error occurs whether the account posting to the list is in the
libertyfp.org domain or billoblog.com domain. Note that "regular" mail
from libertyfp.org does get delivered to outside addresses just fine,
originating from inside the domain or through an email client outside
the domain.
I tried changing the smtp port in mailman.cfg to 587, but that didn't
change anything.
In my reading, there seems to be differing discussions about what
should be in the mydestinations value, but I don't know what it should
be. Here's the current last bit of my main.cf, along with the
mydestinations setting:
mydestination = localhost.org, localhost
# add to the end (add virtual users)
# if specify multiple domains, specify comma or space separated
virtual_mailbox_domains = libertyfp.org
virtual_mailbox_base = /home/vmail
virtual_mailbox_maps = hash:/etc/postfix/virtual-mailbox
virtual_uid_maps = static:20000
virtual_gid_maps = static:20000
# mailman3 changes
owner_request_special = no
always_add_missing_headers = yes
transport_maps = hash:/opt/mailman/mm/var/data/postfix_lmtp
local_recipient_maps = hash:/opt/mailman/mm/var/data/postfix_lmtp
relay_domains = hash:/opt/mailman/mm/var/data/postfix_domains
default_destination_recipient_limit = 30
default_destination_concurrency_limit = 15
virtual_alias_maps = hash:/opt/mailman/mm/var/data/postfix_vmap
header_checks = regexp:/etc/postfix/header_checks
Here's the current values in /opt/mailman/mm/var/data/postfix_domains:
# AUTOMATICALLY GENERATED BY MAILMAN ON 2021-12-27 21:10:32
#
# This file is generated by Mailman, and is kept in sync with the
binary hash
# file. YOU SHOULD NOT MANUALLY EDIT THIS FILE unless you know what
you're
# doing, and can keep the two files properly in sync. If you screw it
up,
# you're on your own.
x.libertyfp.org libertyfp.org
here's postfix_lmtp:
# AUTOMATICALLY GENERATED BY MAILMAN ON 2021-12-27 21:10:32
#
# This file is generated by Mailman, and is kept in sync with the
binary hash
# file. YOU SHOULD NOT MANUALLY EDIT THIS FILE unless you know what
you're
# doing, and can keep the two files properly in sync. If you screw it
up,
# you're on your own.
# Aliases which are visible only in the @x.libertyfp.org domain.
testlist(a)x.libertyfp.org
lmtp:[mail.libertyfp.org]:8024
testlist-bounces(a)x.libertyfp.org
lmtp:[mail.libertyfp.org]:8024
testlist-confirm(a)x.libertyfp.org
lmtp:[mail.libertyfp.org]:8024
testlist-join(a)x.libertyfp.org
lmtp:[mail.libertyfp.org]:8024
testlist-leave(a)x.libertyfp.org
lmtp:[mail.libertyfp.org]:8024
testlist-owner(a)x.libertyfp.org
lmtp:[mail.libertyfp.org]:8024
testlist-request(a)x.libertyfp.org
lmtp:[mail.libertyfp.org]:8024
testlist-subscribe(a)x.libertyfp.org
lmtp:[mail.libertyfp.org]:8024
testlist-unsubscribe(a)x.libertyfp.org
lmtp:[mail.libertyfp.org]:8024
Heres the postfix_vmap that was (finally) successfully created:
# AUTOMATICALLY GENERATED BY MAILMAN ON 2021-12-27 21:10:32
#
# This file is generated by Mailman, and is kept in sync with the
binary hash
# file. YOU SHOULD NOT MANUALLY EDIT THIS FILE unless you know what
you're
# doing, and can keep the two files properly in sync. If you screw it
up,
# you're on your own.
# Virtual mappings for the @libertyfp.org domain.
testlist(a)libertyfp.org
testlist(a)x.libertyfp.org
testlist-bounces(a)libertyfp.org
testlist-bounces(a)x.libertyfp.org
testlist-confirm(a)libertyfp.org
testlist-confirm(a)x.libertyfp.org
testlist-join(a)libertyfp.org
testlist-join(a)x.libertyfp.org
testlist-leave(a)libertyfp.org
testlist-leave(a)x.libertyfp.org
testlist-owner(a)libertyfp.org
testlist-owner(a)x.libertyfp.org
testlist-request(a)libertyfp.org
testlist-request(a)x.libertyfp.org
testlist-subscribe(a)libertyfp.org
testlist-subscribe(a)x.libertyfp.org
testlist-unsubscribe(a)libertyfp.org
testlist-unsubscribe(a)x.libertyfp.org
For what it's worth, here's the extended header info for the mail that
*was* delivered:
Return-Path: <testlist-bounces+fp145=libertyfp.org(a)libertyfp.org>
X-Original-To: fp145(a)libertyfp.org
Delivered-To: fp145(a)libertyfp.org
Received: from mail.libertyfp.org (mail.libertyfp.org [2.56.57.28])
by mail.libertyfp.org (Postfix) with ESMTP id 226F6421BA
for <fp145(a)libertyfp.org>; Mon, 27 Dec 2021 16:27:17 -0500
(EST)
Received: from [10.112.157.251] (unknown [92.60.40.252])
by mail.libertyfp.org (Postfix) with ESMTPSA id F3608421BA
for <testlist(a)libertyfp.org>; Mon, 27 Dec 2021 16:27:11 -0500
(EST)
Message-Id:
<562c2f8aaeb3c9e2ccf198aff197dbd299fc002a.camel(a)libertyfp.org>
From: fp145(a)libertyfp.org <fp145(a)libertyfp.org>
To: testlist(a)libertyfp.org
Date: Mon, 27 Dec 2021 16:27:07 -0500
In-Reply-To:
<eb3380eecc734e240f65ddf974d81ee7dac6ca20.camel(a)libertyfp.org>
References:
<eb3380eecc734e240f65ddf974d81ee7dac6ca20.camel(a)libertyfp.org>
User-Agent: Evolution 3.40.0-1
Mime-Version: 1.0
Message-Id-Hash: FKEDFEFMXBD6YUDWKL235PQRIMUYYPEQ
X-Message-Id-Hash: FKEDFEFMXBD6YUDWKL235PQRIMUYYPEQ
X-Mailfrom: fp145(a)libertyfp.org
X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved;
emergency; loop; banned-address; member-moderation; nonmember-
moderation; administrivia; implicit-dest; max-recipients; max-size;
news-moderation; no-subject; digests; suspicious-header
X-Mailman-Version: 3.3.5
Precedence: list
Subject: [Testlist] Re: test from fp145
List-Id: Test list <testlist.libertyfp.org>
Archived-At:
<https://libertyfp.org/archives/list/testlist@libertyfp.org/message/FKEDFEFM…
>
List-Archive:
<https://libertyfp.org/archives/list/testlist@libertyfp.org/>
List-Help: <mailto:testlist-request@libertyfp.org?subject=help>
List-Owner: <mailto:testlist-owner@libertyfp.org>
List-Post: <mailto:testlist@libertyfp.org>
List-Subscribe: <mailto:testlist-join@libertyfp.org>
List-Unsubscribe: <mailto:testlist-leave@libertyfp.org>
Content-Type: text/plain; charset="us-ascii"
Content-Transfer-Encoding: 7bit
X-Evolution-Source: 14004b3d9af2d67c898fd6d6c16b487f796088f5
I'm beginning to hate postfix.
billo
3 years, 6 months

[MM3-users] Re: Confusing mailman user model
by Gilles Filippini
Gilles Filippini a écrit le 19/07/2020 à 18:00 :
> Mark Sapiro a écrit le 19/07/2020 à 17:30 :
>> On 7/19/20 8:10 AM, Gilles Filippini wrote:
>>> Hi,
>>>
>>> I'm trying to understand the Mailman user model, and I'm confused about
>>> the respective roles of tables 'auth_user' and 'user'.
>>
>>
>> auth_user is a Django auth table. These are the users listed in the
>> Django admin web UI.
>>
>> user is Mailman core's users.
>>
>>
>>> Both have an 'id' column referred to as 'user_id' when used as a foreign
>>> key. But there seems to be no relation at all between them as they use
>>> different ids for the same user.
>>
>>
>> Right, they are unrelated.
>>
>>
>>> Our mailman server was migrated from mailman2 to mailman3 about 1.5 year
>>> ago, and there is an inconsistency I'd like to fix:
>>> 2 of our users have a registered Mailman account with their respective
>>> email addresses in table 'auth_user', but these very same addresses in
>>> the 'address' table are linked to another old admin account in the
>>> 'user' table.
>>
>> Their Mailman account is the 'old' one. the auth_user account is a
>> Django account
>>>
>>> Then if add one of these addresses as a domain owner, it it the old
>>> admin address which is selected instead. How could I fix that?
>>
>>
>> That's because domain owner in a Mailman thing and involvs the Mailman
>> user. You could delete the Django users via the Django admin UI and then
>> re-register them via Postorius. That *might* work.
>
> When login into postorius, it is the Django account that is used, right?
> Then how is the mailman account retrieved from there? It seems UUIDs are
> used in the process, but I fail understanding how, so far. Wouldn't it
> be safe to retrieve the new Mailman account associated to these Django
> users, and link there emails from 'address' table' to them?
Reading the mailman-web source code I understand now that the mailman
account is retrieved from the Django account email address. Then both
users are tied to the same old mailman admin account, and deleting then
registering them again won't change anything on this aspect.
Would this work?
1- For both addresses, update their record in table 'address' to set
'user_id' to null
2- On their next login to Mailman-web, a new mailman account would be
created and associated with their own email address.
Is my understanding correct?
_g.
4 years, 11 months

[MM3-users] Re: Member Issue Discovered
by Brian Carpenter
On 10/19/20 11:32 PM, Mark Sapiro wrote:
> On 10/19/20 7:42 PM, Brian Carpenter wrote:
>> On 10/19/20 10:23 PM, Mark Sapiro wrote:
>>> And the import21 created the user and address records for this user.
>> Does the same thing for a new subscriber as well. So there is no pathway
>> to change a real name that is associated with an email address. None.
>> Zilch. Mailman 2 made this so easy and Mailman 3 made it impossible. I
>> will let someone else file the bug report. You don't really think that
>> this is an issue which means it will be years before it is addressed. So
>> I will save me some time. I will learn to live with it.
>
> I didn't say I didn't think it was a real issue. I mostly questioned
> whether a new subscription should change an existing display_name. I
> agree that there should be a way for a user to change the display_name
> associated with her address. I'm not so sure about a list admin.
Respectively, I think you are asking the wrong question here. The real
question is why isn't a display_name being removed when a list
subscriber is unsubscribed. Also list members being forced into a
powerless role by Mailman 3's architecture have no way of changing a
name except through a list owner unless they register an account but
then again, *even that doesn't allow them to change their display name*.
There are also other use cases in which a list owner will want to
identify portions of their membership roster through the use of the
display_name.
Most list members interact with a Mailing list program via email. I know
you understand that. However it is List owners that are the "real" power
users of Mailman and so the admin interface should be designed in such a
way that empowers List owners. Taking the ability away from List owners
(and List members to make), what should be a simple name change, weakens
them.
> And in any case, I'm only one person. I'm not the only one deciding
> what's important and what's not. I only decide what I want to work on,
> not what anyone else thinks is important or wants to work on, so even if
> I think something is not worth doing, that doesn't mean it won't get
> done, and once again for emphasis, I do thing a user should be able to
> change the display name associated with her address(es).
Again I think we are missing something here from this conversation: data
is not being removed. A list subscriber being removed (unsubscribed)
should have their information totally removed. It is not. I now have one
list owner who realizes this and it is not good. How does this not
violate GDPR? This is why I think all the mailman developers ought to
make this issue a high priority. It is creepy to see a name returned out
of nowhere when someone resubscribes to a list without associating a
name with a second resubscribing. I think this puts List owners at a
disadvantage.
>
> Mailman 3 is totally different from Mailman 2.1 in this respect. Mailman
> 2.1 had no concept of user. All it knew was addresses subscribed to
> lists and an address subscribed to one list had no connection to the
> same address subscribed to another list or being an owner or moderator
> of a list.
I think this should still be the case for non-registered list members.
List owners/moderators are different. They HAVE to be registered users
of Postorius/Affinity in order to manage/moderate a list. I wonder what
the majority of list members' scenarios are. Is the majority scenario in
play today the one where most list members are only subscribed to a
single list on a single mailman instance? Or is it the scenario that is
in majority use the one where a single list member is subscribed to
multiple lists? I think that it is important to find out because it
should govern the development process to a certain degree. This single
approach of having registered user account with multiple associated
email accounts elevates one scenario at the expense of the other. It
also assumes/requires that list members have a registered user account
and I can tell you from my experience that is not going to happen. The
majority of mailman 2 users will not registered with a Mailman 3 admin
interface. Some will of course, the majority will not. Maybe the
behavior should and will change but it will take years for that to
happen. So what I am challenging and questioning here is the approach
where such assumptions are being made already that results in the
weakening of list owners.
>
> Mailman 3 does have a concept of user and addresses belonging to a user.
> This complicates things in some ways. In Mailman 2.1 we could have "The
> Boss <user(a)example.com" as a member of one list and "Just a Peon
> <user(a)example.com>" as a member of another list. In Mailman 3 that is
> not possible unless the addresses are tweaked in some way to make them
> different.
Perhaps there is a better approach here to handle single member
w/multiple subscriptions that doesn't hurt the ability of List owners to
serve the needs of list members who do not have a registered user
account and prevents the removal of data when a SINGLE user unsubscribes
from a list.
>
> You don't seem to be concerned about the case where I subscribe to a
> second list with a different display name and am surprised to find my
> display name changed on the first list, but it's something that I have
> to consider.
I am not concerned because I think such cases are in the extreme
minority. Are you saying that people are now going to be using different
real names associated with their other subscriptions as well and that is
going to be so needed it warrants this complex system that you have come
up with? If someone whats to have a different name associated with a
different subscription/email address then I am going to tell them create
a new user account and use a good password management program to keep
track of their logins. Right now I think this minority use case scenario
is negatively impacting other administrative tasks of Mailman,
particularly in the removal of user data when someone unsubscribes from
a list. Its the use of a square peg being forced into a round hole.
Except in this case most of the holes are round but by golly, we are
going to use that square peg regardless!
>
> As far as filing or not filing an issue, issues in the GitLab trackers
> are how we track these things. Threads on mailing lists are appropriate
> for discussion of issues, but if something is going to get changed or
> fixed, an issue in the tracker is the way to ensure it doesn't get put
> aside and forgotten. If this is as important to you as it seems to be,
> please file the issue.
I will but what is disturbing is that you don't think that the
non-removal of user data in cases of unsubscribing is not important or
even an issue.
--
Brian Carpenter
Harmonylists.com
Emwd.com
4 years, 8 months

[MM3-users] Re: Turn off social logins?
by Torge Riedel
Am 16.02.19 um 13:50 schrieb Stephen J. Turnbull:
> Mark Sapiro writes:
> > On 2/14/19 11:10 PM, Stephen J. Turnbull wrote:
> > > Torge Riedel writes:
> > >
> > > > - there is a way to do this now via settings_local.py, but feels
> > > > a little bit risky if default configuration changes on update of
> > > > mailman
> > >
> > > This should not be true. If it is, we need to fix that. Will check.
> >
> >
> > It is more or less true [...] the only way settings_local.py can
> > change something like INSTALLED_APPS is to redefine INSTALLED_APPS
> > in it's entirety which leads to the possibility of INSTALLED_APPS
> > changing in settings.py and those changes not being picked up in
> > settings_local.py.
>
> That's a different issue from the one I believe Torge is worried
> about, which is an update overwriting settings_local.py. But it's not
> good.
Well, Mark got it what I was meaning. Maybe my explanation was not precise enough.
Hopefully an update is not overwriting settings_local.py in any case. Is it part of delivery and then changed afterwards? Haven't checked that yet.
I personally like the way other services are importing custom settings by including all config files from a given directory. Maybe it is not worth for mailman cause custom settings will not grow very big - so no need to split it in tiny files.
>
> > The way around this is to remove the import of settings_local from
> > settings.py and then put
> >
> > from settings import *
> >
> > at the beginning of settings_local.py and then point Django at
> > settings_local rather than settings.
>
> I don't understand the ramifications of making this change (presumably
> Barry or somebody had a reason for the change from Mailman 2's
> method), but at first glance it looks like a big step in the right
> direction.
>
> > Then you can do things like
> >
> > try:
> > INSTALLED_APPS.remove('allauth.socialaccount.providers.google')
> > except ValueError:
> > pass
> >
> > in settings_local.py except there are still issues because, e.g.,
> > INSTALLED_APPS is defined as a tuple (immutable) and not a list in
> > settings.py.
>
> Given the concerns of privacy advocates, I would say that it would be
> better to have a separate
>
> AUTH_PROVIDERS = ['allauth.socialaccount.providers.google', ...]
>
> in settings_local.py, and merge that in to INSTALLED_APPS. Of course
> removing specific providers would be OK too, but I think that this is
> a place where "deny all / accept what you want" is appropriate.
>
> Steve
>
6 years, 4 months

[MM3-users] Re: Mailman web interface / uwsgi
by Jan Eden
On 2022-11-26 12:02, Mark Sapiro wrote:
> On 11/25/22 23:00, Jan Eden via Mailman-users wrote:
> >
> > proxy_pass http://127.0.0.1:8000; → proxy_pass http://unix:/opt/mailman/mm/var/mailman.sock;
> >
> > and received an error message (as expected):
>
>
> Because that won't work. You can't http to a unix socket in that way.
>
> Use
> ```
> uwsgi_pass unix:/opt/mailman/mm/var/mailman.sock;
> ```
>
> > There are obviously a couple of places where the http-socket on port
> > 8000 is referenced (e.g. mailman_web/settings/mailman.py,
> > /opt/mailman/mm/hyperkitty.cfg). Is there an overview of the
> > required changes when using a different (file) socket?
>
>
> If you configure uwsgi with only a unix `socket` and no `http-socket`,
> nothing will be listening on port 8000. Thus, you need to configure those
> references to public facing URLs and let ngnix determine where to go.
>
> e.g., for mailman-hyperkitty.cfg
> ```
> [general]
> base_url: http://example.com/archives/
> ```
> and in settings.py
> ```
> POSTORIUS_TEMPLATE_BASE_URL = 'https://example.com'
> ```
> to override the `localhost:8000` reference in
> mailman_web/settings/mailman.py.
Thank you! This all makes sense, but uwsgi logged the following error
after applying the changes above:
> Traceback (most recent call last):
> File "/opt/mailman/venv/lib/python3.10/site-packages/django/core/handlers/wsgi.py", line 130, in __call__
> request = self.request_class(environ)
> File "/opt/mailman/venv/lib/python3.10/site-packages/django/core/handlers/wsgi.py", line 78, in __init__
> self.method = environ["REQUEST_METHOD"].upper()
> KeyError: 'REQUEST_METHOD'
> Traceback (most recent call last):
> File "/opt/mailman/venv/lib/python3.10/site-packages/django/core/handlers/wsgi.py", line 130, in __call__
> request = self.request_class(environ)
> File "/opt/mailman/venv/lib/python3.10/site-packages/django/core/handlers/wsgi.py", line 78, in __init__
> self.method = environ["REQUEST_METHOD"].upper()
> KeyError: 'REQUEST_METHOD'
So I checked my local Django configuration and found an include
directive in mysite_nginx.conf (include /etc/nginx/uwsgi_params;) where
the referenced file uwsgi_params contained the following:
> uwsgi_param QUERY_STRING $query_string;
> uwsgi_param REQUEST_METHOD $request_method;
> uwsgi_param CONTENT_TYPE $content_type;
> uwsgi_param CONTENT_LENGTH $content_length;
>
> uwsgi_param REQUEST_URI $request_uri;
> uwsgi_param PATH_INFO $document_uri;
> uwsgi_param DOCUMENT_ROOT $document_root;
> uwsgi_param SERVER_PROTOCOL $server_protocol;
> uwsgi_param REQUEST_SCHEME $scheme;
> uwsgi_param HTTPS $https if_not_empty;
>
> uwsgi_param REMOTE_ADDR $remote_addr;
> uwsgi_param REMOTE_PORT $remote_port;
> uwsgi_param SERVER_PORT $server_port;
> uwsgi_param SERVER_NAME $server_name;
Replicating this setup on the server solved the KeyError problem,
everything works now! I just wonder why these uwsgi parameters need to
be passed explicitly when using a file socket, but not with a http
socket.
Another (unrelated) question: Why is mailman_hyperkitty.cfg placed in
/opt/mailman/mm and not in /etc/mailman3 with the other configuration
files when using the virtualenv installation instructions
(https://docs.mailman3.org/en/latest/install/virtualenv.html#virtualenv-inst…
Thanks again for all your help (and patience)!
- Jan
2 years, 7 months

[MM3-users] Re: Digests not working correctly
by Joel Lord
The May 4th digest that went out was _also_ size-triggered, so this may
have nothing to do with periodic digests at all, and possibly my
periodic digests aren't working. I'm not on any of my own lists in
digest mode, I'm slowly extracting diagnostic information out of people
who are. Also, since this is a ~2 month cycle, it's really difficult to
get data points to work with. I'll need to remember to go in and look
when this settles down again (new cycle of activity started last night)
to see if there's anything left pending.
(venv) root@host2:/home/lists/mailman/venv/bin# pip freeze | grep -i hyper
HyperKitty==1.3.7
On 6/4/2023 10:05 PM, Mark Sapiro wrote:
> On 6/4/23 18:35, Joel Lord wrote:
>>
>> The periodic digests do seem to be coming out. I also now have
>> confirmation that the one message in this morning's digest that was
>> from May 4th was also included in the last digest back on May 4th, so
>> it seems that the one message was left behind in the digest queue when
>> the periodic digest was sent.
>
> I don't see how that can happen. The process that sends a digest renames
> the var/lists/<list-id>/digest.mmdf mailbox file in which the messages
> are accumulated to var/lists/<list-id>/digest.<volume>.<issue>.mmdf,
> where <volume> and <issue> are the volume and issue numbers of that
> digest, and then queues a message in the `digest` queue to tell the
> digest runner to create the digest from the messages in that mbox and
> send it. Thus, it leaves no var/lists/<list-id>/digest.mmdf mailbox file
> behind and that is created anew when the next post arrives. Further, if
> there is a non-empty digest.mmdf file, its messages should be sent no
> later than the next 11 PM `cron digests`.
>
>
>> There was one earlier message to the list back on May 4th, before the
>> one that got duplicated, but I can't tell if that triggered a
>> size-based digest to be sent: the logs aren't clear enough on that
>> detail for me to tell >
>
> OK
>
>
>> Just to inform things:
>>
>> (venv) lists@host2:~/mailman/venv/bin$ pip freeze | grep mailman
>> django-mailman3==1.3.9
>> mailman==3.3.8
>> mailman-hyperkitty==1.2.1
>> mailman-web==0.0.6
>> mailmanclient==3.3.5
>> (venv) lists@host2:~/mailman/venv/bin$ pip freeze | grep hyper
>> mailman-hyperkitty==1.2.1
>
> Actually, it's HyperKitty, not hyperkitty, but I assume HyperKitty is up
> to date as are the others.
>
>> (venv) lists@host2:~/mailman/venv/bin$ pip freeze | grep post
>> postorius==1.3.8
>>
>>
>
--
Joel Lord
2 years

[MM3-users] Re: migrate MM3 list from an old server to a new one
by Odhiambo Washington
On Wed, Aug 7, 2024 at 11:52 AM IEM Network Operation Center (IOhannes m
zmölnig) <noc(a)iem.at> wrote:
> thanks both Mark and Odhiambo (who replied off-list) for your answers.
>
> On 8/6/24 18:40, Mark Sapiro wrote:
> > On 8/6/24 01:43, noc(a)iem.at wrote:
> >>
> >> but how can i export an entire MM3 list (including 20 years of
> >> archives) to some serialization format, and import it again in another
> >> instance?
> >
> >
> > With the dump and other utilities from your database manager. Almost
> > everything is in the database. There are some things in Mailman's var/
> > directory, but those can simply be moved.
> >
>
> urgh.
> while this will (hopefully) work with a fresh installation, i'm somewhat
> afraid whether this will also work for:
> - migrating a single list from one instance to another (at least, if you
> (like me) do not have have an intimate knowledge about the db layout)
>
Hmm.. I think I did something like this in the recent past. I need to
remember how I went about it though, but it could be something like:
(Assuming a virtualenv install) I believe you could:
1. Make a full backup of the old MM2 install - I mean the DB and the MM3
files.
2. update the install to the latest version corresponding to the one on the
new server.
3. Delete all lists with their archives EXCEPT that one list you want to
migrate.
4. Export the DB(s)
6. !! Backup the DBs on the new server (just in case something bad happens!!
7. Import the DB dumps from the old server into the new one. Hopefully,
there are no conflicts with the sites
- importing lists into an instance that is already populated with other
> lists (things like changed db schemas come to my mind)
>
Here again, you should have both sites running at the same software level.
right now my task is to move both some MM3 lists (from an old MM3
> instance) and some MM2 lists onto a single server with a fresh
> installation, so i guess i will be fine.
>
Okay.
> my worries are mostly about future migrations.
>
Sit down and write down your plans. Always come back here for 'sanity
checks' on those plans.
> is a feature-request warranted, or am i worrying too much?
>
A feature to automate your migrations? Have you consulted ChatGPT yet? :-)
--
Best regards,
Odhiambo WASHINGTON,
Nairobi,KE
+254 7 3200 0004/+254 7 2274 3223
In an Internet failure case, the #1 suspect is a constant: DNS.
"Oh, the cruft.", egrep -v '^$|^.*#' ¯\_(ツ)_/¯ :-)
[How to ask smart questions:
http://www.catb.org/~esr/faqs/smart-questions.html]
10 months, 3 weeks

[MM3-users] Re: MM2.1 -> MM3.3 migration. To hold or not hold
by mark@suburbia.org.au
Mark Sapiro wrote:
> To diagnose this further, can you create a test list, set Default action
> to take when a member posts to the list to Hold, mass subscribe an
> address and send a post from that address and see if it's held. It
> should be, and if it is, I think things are working as they should be
> and a test post to the original list from one of these mass subscribed
> members will be held.
I've done some testing as follows:
- Created a test list
- Migrated the existing list in question from its mm21 config.pck to the test list
- Changed the display name to avoid confusion :-)
- Checked moderator settings for the list:
- Default action to take when a member posts to the list: Hold for moderation
- Default action to take when a non-member posts to the list: Discard (no notification)
- Emergency moderation: No
- Accept/Hold/Reject/Discard non-members: all blank
- CSV exported the 247 existing list members
- Pasted all exported member addresses from the CSV into the mass removal web page, *except* for the list-owner. After doing so hoped that they didn't all get an unsubscribe mail. Given that "Send goodbye message" was set to yes, I suspect I did. :-\
- Confirmed List members only had the list owner
- Added a first new test user (me) via mass subscribe, ticked Pre confirm, Pre approved, Pre verified. Received welcome email
- Confirmed List members; list owner "Hold for moderation", test user "None"
- Added a second new test user (me with a second email address) via mass subscribe with same settings as above. Received welcome email
- Modified second test user to "Hold for moderation" in Members list. Noted the Moderation was set to "List default" before changing it to "Hold for moderation"
- Sent an email from test user 1 to the list
- Sent an email from test user 2 to the list
- Sent an email from a third email address that isn't on the list
- Looked at Held messages:
- test user 1 email was held for moderation in Web UI. User 1 received an email indicating as such.
- test user 2 email was held for moderation in Web UI. User 2 received an email indicating as such.
- non-member email was neither held for moderation, nor sent to the list.
> If that is true, I can only think that at the time of that post,
> settings weren't as they are now.
I think for now I will have to assume that's the case, until the next email can be readied against the proper list. If you hear nothing further, assume that this was all based on some random quirk (by humans or machines). I'll update if it happens again.
Cheers,
Mark
7 months, 2 weeks

[MM3-users] Re: SPF check fails for lists subdomain
by Jan Eden
On 2023-01-04 12:40, Mark Sapiro wrote:
> On 1/4/23 11:39, Jan Eden via Mailman-users wrote:
> > Hi,
> >
> > my question is not related to Mailman directly, apologies for using this
> > list. I configured the DNS records for my base domain and my lists
> > subdomain identically (the DMARC policy records are also identical, but
> > not listed here):
> >
> > MX @ mail.eden.one
> > TXT @ "v=spf1 mx ~all"
> > MX lists mail.eden.one
> > TXT lists "v=spf1 mx ~all"
> >
> > A mail 123.123.123.123
> >
> > But both Yahoo and Google report different SPF results for the two domains:
> > What could possibly cause this difference? The SPF test also fails for a
> > [...]
> > different base domain with the same MX and SPF records.
>
> Your spf for lists.mail.eden.one specifies its MX which is also
> lists.mail.eden.one, however mail from that domain arrives from IP
> 123.123.123.123 and presumably an rDNS lookup returns mail.eden.one which is
> not lists.mail.eden.one, thus the failure.
>
> Add the IP 123.123.123.123 to the spf and drop the MX since it doesn't work
>
> TXT lists "v=spf1 123.123.123.123 ~all"
This would explain a lot, but it also invalidates everything I thought
to have understood about DNS records. Maybe the abbreviated records
above (quoted from my provider's web interface) were misleading, so
here's the output of dig:
eden.one. 60 IN MX 10 mail.eden.one.
eden.one. 60 IN TXT "v=spf1 mx ~all"
lists.eden.one. 60 IN MX 10 mail.eden.one.
lists.eden.one. 60 IN TXT "v=spf1 mx ~all"
mail.eden.one. 60 IN A 123.123.123.123
So an MX lookup for both eden.one and lists.eden.one returns the
hostname mail.eden.one, which points to the address 123.123.123.123.
The SPF records for eden.one and lists.eden.one refer to the respective
MX records (with the same target hostname). According to RFC 7208[1],
the mx mechanism
"matches if <ip> is one of the MX hosts for a domain. [...]
check_host() first performs an MX lookup on the <target-name>. Then
it performs an address lookup on each MX name returned. The <ip> is
compared to each returned IP address. [...] If any address matches,
the mechanism matches."
So in both cases, the MX mechanism should first retrieve mail.eden.one, and
then 123.123.123.123 via DNS queries, and should match accordingly when
the message was sent from mail.eden.one/123.123.123.123.
Although I could specify the IP address in my SPF records directly (as
you suggested), I do hope that my understanding of DNS records laid out
above is not entirely misguided. My current setup does work as expected
for eden.one, after all.
- Jan
[1] https://www.rfc-editor.org/rfc/rfc7208#section-5.4
2 years, 5 months

[MM3-users] Timeouts
by tlhackque
On 25-Apr-21 18:08, Mark Sapiro wrote:
> On 4/25/21 2:20 PM, Andrew Hodgson wrote:
>> Hi,
>>
>> Hyperkitty 1.3.4.
>>
>> I am trying to download a complete list mbox by going to all threads view
>> and using the download option. I have tried a couple of tools (Gunzip and
>> Winrar) and both are giving me an unexpected end of file when trying to decompress the gz file.
>>
>> Here is the list URL I am using: https://lists.hodgsonfamily.org/hyperkitty/list/plextalk@lists.hodgsonfamil…
> Depending in the web server configuration, timeouts can occur when
> downloading large archive mboxes. instead of downloading the entire mbox
> with
> <https://lists.hodgsonfamily.org/hyperkitty/list/plextalk@lists.hodgsonfamil…>,
> do it in pieces by adjusting start and end. e.g.
>
> <https://lists.hodgsonfamily.org/hyperkitty/list/plextalk@lists.hodgsonfamil…>
>
> <https://lists.hodgsonfamily.org/hyperkitty/list/plextalk@lists.hodgsonfamil…>
>
> <https://lists.hodgsonfamily.org/hyperkitty/list/plextalk@lists.hodgsonfamil…>
>
>
> Although, I don't think timing out is the issue, and I'm not sure what
> is, but I think it has something to do with messages in the archive. If
> I try to get the 3 pieces as above, the first piece with
> start=2008-02-19&end=2012-12-31 works but the others don't and even
the
> smaller
>
> <https://lists.hodgsonfamily.org/hyperkitty/list/plextalk@lists.hodgsonfamil…>
>
> fails the same way.
>
> If I try to get 2013 month by month, all work except December which
> gives me an internal server error. What's the traceback from that error.
>
The described timeouts are something that hyperkitty ought to be able to
avoid. For apache, the timeout is idle time between blocks of output.
Hyperkitty can avoid this by generating the archive in segments (based
on size, or elapsed time), flushing its output buffer, generating a
multi-file archive, and/or using Transfer-Encoding: chunked (chunked
doesn't work for http/2). It ought to be able to break the work into
blocks of "n" messages & do something to generate output. Besides
avoiding timeouts, working in segments allows the GUI to display
meaningful progress (e.g. if you're loading with XMLHttpRequest,
"onprogress") It really oughtn't be up to the user to break up the
request.
Until then: the apache directive is "TimeOut" (or "ProxyTimeout"), with
a default value of 60 (seconds). It's a server config/virtual host
parameter, so if you're running in an environment where you only have
.htaccess, you need admin help or you're out of luck.
Other webservers (especially those with accelerators) may have more
granular timeouts.
4 years, 2 months

[MM3-users] Re: Attack on Mailman Server?
by Eggert Ehmke
In the log file there are several entries like this:
ERROR 2023-03-09 13:09:34,066 53357 django.request Internal Server Error: /accounts/
signup/
Traceback (most recent call last):
File "/opt/mailman/venv/lib/python3.9/site-packages/django/core/handlers/exception.py",
line 47, in inner
response = get_response(request)
File "/opt/mailman/venv/lib/python3.9/site-packages/django/core/handlers/base.py", line
181, in _get_response
response = wrapped_callback(request, *callback_args, **callback_kwargs)
File "/opt/mailman/venv/lib/python3.9/site-packages/django/views/generic/base.py", line
70, in view
return self.dispatch(request, *args, **kwargs)
File "/opt/mailman/venv/lib/python3.9/site-packages/django/utils/decorators.py", line 43, in
_wrapper
return bound_method(*args, **kwargs)
File "/opt/mailman/venv/lib/python3.9/site-packages/allauth/decorators.py", line 18, in
wrap
resp = ratelimit.consume_or_429(request, action=action, **rl_kwargs)
File "/opt/mailman/venv/lib/python3.9/site-packages/allauth/ratelimit.py", line 77, in
consume_or_429
return render(request, "429." + app_settings.TEMPLATE_EXTENSION, status=429)
File "/opt/mailman/venv/lib/python3.9/site-packages/django/shortcuts.py", line 19, in
render
content = loader.render_to_string(template_name, context, request, using=using)
File "/opt/mailman/venv/lib/python3.9/site-packages/django/template/loader.py", line 61, in
render_to_string
template = get_template(template_name, using=using)
File "/opt/mailman/venv/lib/python3.9/site-packages/django/template/loader.py", line 19, in
get_template
raise TemplateDoesNotExist(template_name, chain=chain)
django.template.exceptions.TemplateDoesNotExist: 429.html
So what is special about this 429.html?
Am Donnerstag, 9. März 2023, 21:26:03 CET schrieb Mark Sapiro:
> On 3/9/23 11:34, Eggert Ehmke via Mailman-users wrote:
> > I had some attacks on my wordpress homepage today, I added some IPs to the
> > blacklist of my firewall. At the same time, I got several reports like
> > this:
> >
> > Internal Server Error: /accounts/signup/
> >
> > TemplateDoesNotExist at /accounts/signup/
> > 429.html
>
> I suspect that's a coincidence.
>
> > Request Method: OPTIONS
> > Request URL: https://lists.eehmke.de/accounts/signup/
> > Django Version: 3.2.16
> > Python Executable: /opt/mailman/venv/bin/uwsgi
> > Python Version: 3.9.2
> > Python Path: ['.', '', '/etc/mailman3', '/usr/lib/python39.zip',
> > '/usr/lib/
> > python3.9', '/usr/lib/python3.9/lib-dynload', '/opt/mailman/venv/lib/
> > python3.9/site-packages']
> > Server time: Thu, 09 Mar 2023 13:09:34 +0100
> >
> > So it seems there were attempts to register new users but this caused this
> > internal error. Where can I send the complete error message?
>
> I would look in the web server logs to see what the actual accesses
> were. I'm guessing you'll find that some bot or script kiddies did a GET
> of /accounts/signup/429.html.
>
> You could also look for more detail in whatever log Django writes. This
> is defined in Django's settings as
> LOGGING['handlers']['file']['filename'] and is often Mailman's
> var/logs/mailmansuite.log. If you followed
> https://docs.mailman3.org/en/latest/install/virtualenv.html#initial-configur
> ation it is /opt/mailman/web/logs/mailmanweb.log.
2 years, 3 months

[MM3-users] Re: old usernames appearing in mailman.log
by Ken Alker
--On Sunday, June 25, 2023 3:26 PM -0700 Mark Sapiro <mark(a)msapiro.net>
wrote:
> On 6/25/23 2:27 PM, Ken Alker wrote:
>> --On Sunday, June 25, 2023 1:14 PM -0700 Mark Sapiro <mark(a)msapiro.net>
>> wrote:
>> I see this in the logs from just after midnight:
>>
>> Jun 25 00:13:04 2023 (386086) No cached copy of the public suffix list
>> found
>> Jun 25 00:13:04 2023 (386086) ACCEPT:
>> <7500f0e2-1ae1-309d-60d7-6e592c7abf7a(a)west.net>
>> Jun 25 00:13:04 2023 (386090) HyperKitty failure on
>> https://lists.netlojix.com/hyperkitty/api/mailman/urls:
>>
>> Followed by a huge amount of HTML (strange).
>
> This is all from one post.
>
> The first is normal it just says that Mailman's
> var/public_suffix_list.dat doesn't exist, but it should be retrieved from
> https://publicsuffix.org/list/public_suffix_list.dat and then saved at
> var/public_suffix_list.dat so it doesn't need to be retrieved from the
> web again until the saved copy is older that the configured
> dmarc.cache_lifetime (default = 7 days, so that message) after which time
> the message will be 'Cached copy of public suffix list is out of date'
>
> The second is acceptance of the post.
>
> The third is a failure in archiving the message. Th HTML should contain
> an error message with a traceback which should help determine the problem.
>
>
>> Is there a way to kick it into re-running whatever it does at midnight
>> so I can test this again after putting the public suffix list back? I
>> assume I can just execute "mailman-web runjobs daily", but will this
>> mess things up, or is it OK to run it mid-day without stopping anything
>> first?
>
>
> Midnight is a coincidence in this case. the above are all due to the post
> with Message-ID: <7500f0e2-1ae1-309d-60d7-6e592c7abf7a(a)west.net>
>
> The cached var/public_suffix_list.dat should now be there with a
> timestamp of Jul 02 00:13:04 (7 days from Jun 25 00:13:04)
Yes, thanks.
>> Is the last (third) log line excerpt simply a result of the first, or do
>> I have something else messed up?
>
> The third is not because of the first. It is because of some issue with
> archiving that post.
I have studied the output, looked at the code lines referenced in the
Traceback, and I can't figure out the problem (I feel like the sad guy on
the side of the street with his hood up staring into the engine bay with
stream pouring out and not knowing what to do next). I did some analyses
on the log file and determined that there are 71 messages it is having
problems processing and there are 71 messages "stuck" in
/opt/mailman/mm/var/archives/hyperkitty/spool/ (and that it has tried to
process each message about 20 times). Since upgrading to V3.3.8 I've not
seen new messages get stuck like this (although it's only been running
smoothly for 24 hours now and there hasn't been much activity). But I'm
suspecting there was something awry between the conversion from V2 to V3 in
February and me installing V3.3.8 that caused this (based on message time
stamps). It is HIGHLY likely these messages are in the archiving spool as
a result of me unshunting the shunt queue and that they are copies of the
messages that got delivered to the subscribers when I did that... but are
now hung up in the archiving process.
Following is an excerpt from mailman.log. Note that the "first section"
(from DOCTYPE at top to 404 at bottom) is repeated four times (maybe not
identical; but similar) (so I did not include it to save room) before the
Traceback appears.
Jun 25 00:13:04 2023 (386086) No cached copy of the public suffix list found
Jun 25 00:13:04 2023 (386086) ACCEPT:
<7500f0e2-1ae1-309d-60d7-6e592c7abf7a(a)west.net>
Jun 25 00:13:04 2023 (386090) HyperKitty failure on
https://lists.netlojix.com/hyperkitty/api/mailman/urls:
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>lists.netlojix.com</title>
<link rel="shortcut icon" href="/static/postorius/img/favicon.ico">
<link rel="stylesheet"
href="/static/postorius/libs/bootstrap/css/bootstrap.min.css">
<link rel="stylesheet" href="/static/django-mailman3/css/main.css">
<link rel="stylesheet" href="/static/postorius/css/style.css">
<link rel="stylesheet"
href="/static/postorius/libs/fonts/font-awesome/css/font-awesome.min.css"
type="text/css" media="all" />
<!-- HTML5 shim and Respond.js for IE8 support of HTML5 elements and
media queries -->
<!-- WARNING: Respond.js doesn't work if you view the page via file://
-->
<!--[if lt IE 9]>
<script
src="/static/postorius/libs/html5shiv/html5shiv.min.js"></script>
<script src="/static/postorius/libs/respond/respond.min.js"></script>
<![endif]-->
</head>
<body>
<nav class="navbar navbar-expand-md navbar-light bg-light navbar-default">
<div class="container">
<div class="navbar-header">
<button type="button" class="navbar-toggler collapsed"
data-toggle="collapse" data-target="#header-nav" aria-expanded="false">
<span class="sr-only">Toggle navigation</span>
<span class="fa fa-bars"></span>
</button>
<a class="navbar-brand" href="/mailman3/lists/"><span><img
src="/static/postorius/img/mailman_logo_small_trans.png" alt="Mailman
logo"/> Postorius</span></a>
</div>
<div class="collapse navbar-collapse" id="header-nav">
<ul class="nav navbar-nav mr-auto">
<li class="nav-item"><a href="/mailman3/lists/"
class="nav-link">
<span class="fa fa-envelope"></span>
Lists
</a></li>
<li class="nav-item"><a href="/archives/"
class="nav-link">
<span class="fa fa-comment"></span>
Archives
</a></li>
</ul>
<ul class="nav navbar-nav navbar-right">
<li class="nav-item"><a class="nav-link"
href="/accounts/login/?next=/hyperkitty/api/mailman/urls">
<span class="fa fa-sign-in"></span>
Login
</a></li>
<li class="nav-item"><a class="nav-link"
href="/accounts/signup/?next=/hyperkitty/api/mailman/urls">
<span class="fa fa-user-plus"></span>
Sign Up
</a></li>
</ul>
</div>
</div>
</nav>
<div class="container" role="main">
<h1>Page not found</h1>
<div class="alert alert-danger">This page either doesn't exist, or it
moved somewhere else.</div>
</div>
<footer class="footer">
<div class="container">
<p class="text-center">
<a href="https://postorius.readthedocs.org">Postorius
Documentation</a>
•
<a href="http://list.org">GNU Mailman</a>
•
Postorius Version 1.3.8
</p>
</div>
</footer>
<script
src="/static/postorius/libs/jquery/jquery-3.6.0.min.js"></script>
<script
src="/static/postorius/libs/popperjs/popper-v1.11.0.min.js"></script>
<script
src="/static/postorius/libs/bootstrap/js/bootstrap.min.js"></script>
<script src="/static/django-mailman3/js/main.js"></script>
<script src="/static/postorius/js/script.js"></script>
<script>
// Add the .js-enabled class to the body so we can style the elements
// depending on whether Javascript is enabled.
$(document).ready(function(){
$("body").addClass("js-enabled");
});
</script>
</body>
</html>
(404)
... above portion of log (or similar) repeats three more times ...
Jun 25 00:13:05 2023 (386083) Traceback (most recent call last):
File
"/opt/mailman/venv/lib/python3.8/site-packages/mailman_hyperkitty/__init__.py",
line 158, in _archive_message
url = self._send_message(mlist, msg)
File
"/opt/mailman/venv/lib/python3.8/site-packages/mailman_hyperkitty/__init__.py",
line 228, in _send_message
raise ValueError(result.text)
ValueError:
2 years

[MM3-users] Re: MM3 templates
by Odhiambo Washington
On Thu, Feb 16, 2023 at 10:26 AM Mark Sapiro <mark(a)msapiro.net> wrote:
> On 2/15/23 23:04, Odhiambo Washington wrote:
> >
> > The last time I referred to the link, I deliberately duplicated the <LC>
> > folder in two locations:
> > [09:51 ~ ]$ ls -al /opt/mailman/mm/var/templates/site/en/
> > total 48
> > drwxr-xr-x 2 mailman mailman 512 Feb 14 08:53 .
> > drwxr-xr-x 3 mailman mailman 512 Feb 14 08:53 ..
> > -rw------- 1 mailman mailman 615 Jan 17 13:57
> domain:admin:notice:new-list.txt
> > -rw------- 1 mailman mailman 341 Jan 17 13:54
> list:admin:action:post.txt
> > -rw------- 1 mailman mailman 158 Dec 17 13:32
> list:member:digest:footer.txt
> > -rw------- 1 mailman mailman 452 Jan 17 13:54
> list:member:digest:masthead.txt
> > -rw------- 1 mailman mailman 137 Jan 17 13:55
> list:member:generic:footer.txt
> > -rw------- 1 mailman mailman 1219 Dec 8 15:12
> list:member:regular:footer.txt
> > -rw------- 1 mailman mailman 944 Jan 17 15:50
> list:user:action:subscribe.txt
> > -rw------- 1 mailman mailman 247 Jan 17 13:56
> list:user:notice:post.txt
> > -rw------- 1 mailman mailman 802 Jan 17 13:56
> list:user:notice:probe.txt
> > -rw------- 1 mailman mailman 639 Jan 17 13:57
> list:user:notice:welcome.txt
> >
> > Yet, it is NOT being picked. So definitely something is wrong somewhere.
>
>
> If you have the same list:* file in both
> /opt/mailman/mm/var/templates/site/en/ and
> /opt/mailman/mm/var/templates/lists/kictanet.lists.kictanet.or.ke/en/
> the ones in the lists directory will take precedence for that list over
> the ones in the site directory.
>
In my case, I had the exact same files in the two paths and the
list:user:action:subscribe.txt was still not used in my tests.
Why?
I have now created the directory:
mkdir -p /opt/mailman/mm/var/templates/domains/lists.kictanet.or.ke/en/
And I have placed the same files in there. Gearing up for a test to see if
the template will be used this time around.
> See
>
> https://gitlab.com/mailman/mailman/-/blob/master/src/mailman/utilities/i18n…
> for a discussion of the search order.
>
Will do.
> >>
> >> Are the other templates such as list:member:regular:footer.txt used?
> >>
> >
> > I do see that in posts to the list, but I believe that is perhaps only
> > working because the list had that footer when it was imported from MM2.
>
> A template from import21 of the kictanet(a)lists.kictanet.or.ke list will
> be stored in the
> /opt/mailman/mm/var/templates/lists/kictanet.lists.kictanet.or.ke/en/
> directory.
>
It wasn't a template per se. It was the regular nondigest msg_footer from
MM2.
--
Best regards,
Odhiambo WASHINGTON,
Nairobi,KE
+254 7 3200 0004/+254 7 2274 3223
"Oh, the cruft.", egrep -v '^$|^.*#' ¯\_(ツ)_/¯ :-)
2 years, 4 months

[MM3-users] Re: Installed from Howto_Install_Mailman3_On_Debian10, web not quite working
by Volkmar Grote
Hi Mark,
On 07.05.23 01:31, Mark Sapiro wrote:
> On 5/6/23 16:02, volkmar(a)grote-family.com wrote:
>>
>> My urls.py:
>>> (venv) mailman@me:/opt/mailman/mm$ grep -v "^#" urls.py
>>> from django.contrib import admin
>>> from django.urls import include, reverse_lazy, re_path
>>> from django.views.generic import RedirectView
>>>
>>> urlpatterns = [
>>> re_path(r'^$', RedirectView.as_view(
>>> url=reverse_lazy('list_index'),
>>> permanent=True)),
>>> re_path(r'^postorius/', include('postorius.urls')),
>>> re_path(r'^hyperkitty/', include('hyperkitty.urls')),
>>> re_path(r'', include('django_mailman3.urls')),
>>> re_path(r'^accounts/', include('allauth.urls')),
>>> # Django admin
>>> re_path(r'^admin/', admin.site.urls),
>>> ]
>
>
> We and the various docs are inconsistent about 'postorius' vs
> 'mailman3' and 'hyperkitty' vs 'archives' in urls. Add these
>
> re_path(r'^mailman3/', include('postorius.urls')),
> re_path(r'^archives/', include('hyperkitty.urls')),
>
> to your urlpatterns list in urls.py to cover both variants.
>
thanks for the quick reply.
I am one step closer to a solution,
"http://127.0.0.1:8000/postorius/lists/?all-lists#" seems to work now.
I get the functionality, but it looks ugly w/o any graphics, for which I
get yet another, slightly similar, error message:
>
>
> Page not found (404)
>
> Request Method: GET
> Request URL:
> http://127.0.0.1:8000/static/postorius/img/mailman_logo_small_trans.png
>
> Using the URLconf defined in |urls|, Django tried these URL patterns,
> in this order:
>
> 1. ^$
> 2. ^mailman3/
> 3. ^archives/
> 4. ^postorius/
> 5. ^hyperkitty/
> 6. ^user-profile/delete$ [name='mm_user_account_delete']
> 7. ^user-profile/$ [name='mm_user_profile']
> 8. ^accounts/
> 9. ^admin/
>
> The current path, |static/postorius/img/mailman_logo_small_trans.png|,
> didn’t match any of these.
>
The file exists, world readable:
> mailman@me:/opt/mailman/mm$ find . -name mailman_logo_small_trans.png -ls
> 124610 2 -rw-r--r-- 1 mailman mailman 1163 May 6 12:18
> ./venv/lib/python3.9/site-packages/postorius/static/postorius/img/mailman_logo_small_trans.png
> 125831 2 -rw-r--r-- 1 mailman mailman 1163 May 6 12:19
> ./static/postorius/img/mailman_logo_small_trans.png
Q&D MM3 configuration check:
> mailman@me:/opt/mailman/mm$ grep -i static *cfg *py|grep -v "#"
> settings_local.py: 'django.contrib.staticfiles',
> settings.py: 'django.contrib.staticfiles',
> settings.py: 'django.template.context_processors.static',
> settings.py:STATIC_ROOT = os.path.join(BASE_DIR, 'static')
> settings.py:STATIC_URL = '/static/'
> settings.py:STATICFILES_DIRS = (
> settings.py:STATICFILES_FINDERS = (
> settings.py: 'django.contrib.staticfiles.finders.FileSystemFinder',
> settings.py: 'django.contrib.staticfiles.finders.AppDirectoriesFinder',
Nginx, /etc/nginx/conf.d/me.domain.de.conf
> server {
> listen 80;
> listen [::]:80;
>
> server_name me.domain.de;
> ...
> location /static/ {
> alias /opt/mailman/mm/static/;
> }
Again, many thanks in advance for any clue
Volkmar
2 years, 1 month

[MM3-users] Solved Re: after last upgrade I've got a CSRF failed verification
by Guillermo Hernandez (Oldno7)
El 27/10/22 a las 5:48, Mark Sapiro escribió:
> On 10/26/22 04:33, Guillermo Hernandez (Oldno7) via Mailman-users wrote:
>>
>> I did it via pip and all seems to be working, but when I try to
>> discard or accept any message via postorius it shows a Forbidden 403
>> error CSRF verification failed.
>>
>> In my settings.py I have commented out these variables:
>>
>> # Other security settings
>> # SECURE_SSL_REDIRECT = True
>> # If you set SECURE_SSL_REDIRECT to True, make sure the
>> SECURE_REDIRECT_EXEMPT
>> # contains at least this line:
>> # SECURE_REDIRECT_EXEMPT = [
>> # "archives/api/mailman/.*", # Request from Mailman.
>> # ]
>> # SESSION_COOKIE_SECURE = True
>> # SECURE_CONTENT_TYPE_NOSNIFF = True
>> # SECURE_BROWSER_XSS_FILTER = True
>> # CSRF_COOKIE_SECURE = True
>> # CSRF_COOKIE_HTTPONLY = True
>> # X_FRAME_OPTIONS = 'DENY'
>>
>> I've been messing with them whith no results. It's like it lacked
>> some value in some template...
>
>
> It's not an issue with the code per se or the templates. These updates
> are all installed on mail.python.org and lists.mailman3.org and are
> working fine.
>
> After upgrading did you run
>
> django-admin collectstatic --clear
> django-admin compress
> django admin migrate
Since I made all the mailman3 enviroment wide server open (not using
venv) I already executed the migration doing a
su -m mailman3 -c "python3 manage.py collectstatic"
su -m mailman3 -c "python3 manage.py migrate"
Being mailman3 the user who runs all of mailman3 related stuff
I had problems doing the migrate part, showing an error of lacking
perms. I solved it running the migration under root (I know it could be
trouble after, but...)
After that the compress part showed errors... but the postorius web
maintenance was working well except for the CSRF error verification. I
will trace the compress errors and will try to find the problem later.
With your point to the CSRF_TRUSTED_ORIGINS parameter, I can now do the
accept or discard part of a receiving message to the lists (I put below
the config that is working for me).
All seems to be working now flawlessly.
Thanks once again for your guidance.
############
SESSION_COOKIE_SECURE = True
SECURE_CONTENT_TYPE_NOSNIFF = True
SECURE_BROWSER_XSS_FILTER = True
CSRF_COOKIE_SECURE = True
CSRF_COOKIE_HTTPONLY = True
X_FRAME_OPTIONS = 'DENY'
#
CSRF_TRUSTED_ORIGINS = [
"https://*.mydomain-example.xxx",
"https://mydomain-example",
"https://mydomain",
]
############
>
> If you have and it doesn't help, you probably need to add
> CSRF_TRUSTED_ORIGINS to your settings.py.
>
> See
> https://docs.djangoproject.com/en/4.1/ref/settings/#csrf-trusted-origins
> and note the differences between Django <4.0 and >=4.0.
>
--
___________________________________________
Mailman's content filtering has removed the
following MIME parts from this message.
Content-Type: image/png
Name: firma-GHP-emails.png
Replaced multipart/alternative part with first alternative.
2 years, 8 months

[MM3-users] Re: Flushing/syncing hyperkitty with mailman
by Eric Abrahamsen
On 06/16/18 19:46 PM, Mark Sapiro wrote:
> On 06/16/2018 06:38 PM, Eric Abrahamsen wrote:
>>
>>
>> A bump for this, I've been getting this series of errors once a minute
>> for weeks now. There must be some way to clear out dangling thread
>> references? And I take it that for the meantime we shouldn't be using
>> the "delete thread" feature of hyperkitty...
>>
>>> [Q] ERROR Failed [rebuild_thread_cache_votes] - Thread matching query does not exist.
>>> [Q] INFO Process-1:1 processing [rebuild_email_cache_votes]
>>> [Q] ERROR Failed [rebuild_email_cache_votes] - Email matching query does not exist.
>>> [Q] INFO Process-1:2 processing [rebuild_thread_cache_votes]
>>> [Q] ERROR Failed [rebuild_thread_cache_votes] - Thread matching query does not exist.
>>> [Q] INFO Process-1:3 processing [rebuild_email_cache_votes]
>>> [Q] ERROR Failed [rebuild_email_cache_votes] - Email matching query does not exist.
>>> [Q] INFO Process-1:4 processing [rebuild_thread_cache_votes]
>>> [Q] ERROR Failed [rebuild_thread_cache_votes] - Thread matching query does not exist.
>>>
>>> Is there something more I should be doing to sync hyperkitty's database
>>> with mailman? I've got the crontab file in place, and that appears to be
>>> running without error. Anything else?
>
>
> Except that 'django-admin runjobs minutely' is probably what's producing
> the errors.
Yes, I guess that was poorly phrased...
> You might try 'django-admin runjob empty_threads' (normally a monthly
> job) or 'django-admin runjob thread_order_depth' (normally a yearly
> job). I don't know if they will clear this up or not, but I don't think
> it would hurt to try.
>
> See 'django-admin runjob --list' to see the various jobs and note that
> 'django-admin runjob update_index' which runs minutely and does an
> incremental update is not the same as 'django-admin update_index' which
> only runs manually and does a full search index update.
I've tried all the above with no luck, and am getting ready to dive a
bit deeper. It's been a bit confusing tracking all the code flows. The
rebuild_thread_cache_votes error occurs once a minute, at second 21. The
rebuild_email_cache_votes error is also once a minute, but at second 56.
Am I right that the only job that runs once a minute is the "runjob
update_index" command, and that the error must be (eventually) arising
from there? Does it seem meaningful that the two errors are offset by
around 30 seconds? Lastly, searching the source for the
rebuild_(email|thread)_cache_votes functions, they only seem to be
called within the "on_vote_added" method of Email and Thread objects,
but I don't see how that can be the source of the errors (as the objects
in question obviously exist). So it must be update_index, which means I
should be looking in haystack (ha) for whatever eventually calls these
functions. Does that all sound correct?
Thanks for your pointers,
Eric
7 years

[MM3-users] Re: Disable archives per list
by Stephen J. Turnbull
Bernd Wurst writes:
> Am 25.02.21 um 22:01 schrieb Mark Sapiro:
> > Normally a list admin can select which of the enabled archivers is
> > active for that list via Postorius. To prevent this, you would have to
> > modify Postorius. It would be easy enough to just remove settings from
> > the relevant templates.
>
> This will take effect for all lists at once, I suppose. :(
I'm not familiar with the content of Postorius's templates, but they
support all of the Django features, so you can filter out the settings
for specific lists. It would require code and database schema changes
to make that configurable from Postorius, I think.
> Hyperkitty has a rather cool frontend but stores all messages from all
> lists together in one database table. Additionally, neither Mailman nor
> Hyperkitty seems to know or tell anything about archive sizes of a list.
> This is horribly for accounting.
Mailman core doesn't know anything about archives except where you've
told it to send them.
Historical note: I'm not saying it was a good idea, but the folks who
designed HyperKitty were aiming at the Fedora use-case. There's a
fair amount of cross-posting between Fedora lists, so I think this
makes sense for them both from the indexing and from the storage point
of view. I doubt they were thinking about the hosting perspective.
> So I thought if I can have a separate hyperkitty installation per user
> without having to duplicate the whole mailman.
You could do that, but it requires a separate port or domain for
each. If you're already aliasing a server (or a server farm) for
virtual domains, then that's no problem.
> Alternatively, I'd like to enable archiving only for some customers
> that buy a suitable plan.
> I did not really get into mailman plugins.
I don't think anybody has gotten into them.
> Is is possible for plugins to hook into such settings?
Since archiving involves getting the message from Mailman core, yes.
Plugins can only deal with that end though. Everything else is
controlled by the archiver itself.
Without a plugin, you could disable archiving somewhat easily by
giving each list a different posting pipeline that doesn't have the
'to-archive' handler in it. This wouldn't stop the list admin from
configuring, but ... there wouldn't be any archives there. I don't
know if that deserves a smiley. :-/ Unfortunately this would be
annoying because you'd have to go in and modify for each list.
With a plugin, Mailman core could refuse to configure a archive.
However, stock Postorius wouldn't know anything about that. It would
just see a "refused" response in the REST protocol, but without
modifying Postorius, I suspect it would just log and display an error
to the user. And without code changes Postorius can't provide a good
UI for that.
Steve
4 years, 4 months

[MM3-users] Re: Mailman3 on FreeBSD
by John Poltorak
Regarding location of mailman.cfg...FreeBSD adopt a strict directory
hierachy
https://www.freebsd.org/cgi/man.cgi?hier(7)
Anything installed outside the base OS belongs in /usr/local
I guess that issue is something for the FreeBSD porters of Mailman3...
I'll use /etc/mailman.cfg for the time being but I don't know what should
go in it. Can I see an example?
The other problem regarding sqlite was solved by
pkg install databases/py36-sqlite3
I'll get back to the install docs now. Thanks showing interest.
On Sun, Aug 13, 2017 at 2:25 AM, Abhilash Raj <maxking(a)asynchronous.in>
wrote:
> On Sat, 12 Aug 2017 18:10:49 -0700
> Mark Sapiro <mark(a)msapiro.net> wrote:
>
> > On 08/12/2017 04:51 PM, Barry Warsaw wrote:
> > > On Aug 10, 2017, at 16:32, John Poltorak <karotlopj(a)gmail.com>
> > > wrote:
> > >>
> > >> On FreeBSD they ought to be in /usr/local/etc/mailman.cfg however
> > >> I don't see any indication as to what I should put in this file
> > >> and if it was in /usr/local/etc/mailman.cfg then how would mailman
> > >> find it?
> > >
> > > It wouldn’t by default. Right now Mailman does not search
> > > for /usr/local/etc/mailman.cfg, but that wouldn’t be a difficult
> > > change to add. I’m not sure whether that would makes sense as a
> > > general default or not. I’m not up on the FreeBSD conventions and
> > > standards here; can you explain why /usr/local/etc is preferred
> > > over /etc on that distro?
> >
> >
> > I was hoping Abhilash would chime in here, because I think John is
> > using the docker image and there's probably a specific path for
> > mailman.cfg.
>
> As per his first message, I think John is using the prod setup from the
> documentaion[1].
>
> I don't have anything much to add on top of what Barry mentioned, it
> looks like something is wrong with the Python install and missing
> Sqlite3 module.
>
> The documentation does mention the paths where Core looks for
> configuration file and anything else can be specified using -C or
> MAILMAN_CONFIG_FILE environment variable.
>
> [1]: http://docs.mailman3.org/en/latest/prodsetup.html
>
> > As far as what goes in it, it could even be empty if you want to
> > accept all the defaults, but you probably want at least
> >
> > [mailman]
> > site_owner: real_person(a)example.com
> >
> > I expect if you do
> >
> > find -name mailman.cfg
> >
> > in your installation, you'll find at least examples.
> >
>
> thanks,
> Abhilash
>
> _______________________________________________
> Mailman-users mailing list
> mailman-users(a)mailman3.org
> https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/
>
>
7 years, 10 months

[MM3-users] Re: add custom styles to postorius list creation menu
by mhazan@mandint.org
Le 2022-05-03 09:44, mhazan(a)mandint.org a écrit :
> Le 2022-05-02 17:32, Mark Sapiro a écrit :
>> On 5/2/22 06:39, Michael Hazan wrote:
>>> Hello,
>>>
>>> When creating a list via postorius, i can see 3 style appear
>>> (announce, discussion, private). Is it possible to either create a
>>> new style and add it to that list or modify one of those style ?
>>
>>
>> See this thread
>> https://lists.mailman3.org/archives/list/mailman-users@mailman3.org/thread/…
>>
>>
>
> Thanks i will look into setting up that plugin, hopefully an easier
> way to do that can make it's way to the default install.
working on that plugin, i have found where to inserts the various
setting, however it's not clear what types and possibles value are
excepted for each ? ie "advertised" is bool True/false, but what about
"default_member_action" ? i've tried hold 'hold' "hold" all throw error
when trying to apply the style. i cannot find the types in the
documentation and all the other non bool settings.
>>> Also, coming from mailman2, you could directly set the members post
>>> moderation action when subscribing, now you can only do it via the
>>> user menu, is there a way to automate this in mm3 ?
>>
>>
>> I don't understand what you mean here. In MM 2.1 a member had only one
>> setting - moderated yes or no and if moderated there was a list
>> setting for the moderation action. There was also a list setting for
>> whether new members were moderated by default. How were you setting
>> the new member's moderation when subscribing?
>>
>> You are correct that when subscribing a new member, the member gets
>> the default action for members and different action has to be set in a
>> separate operation. I don't think this is significantly different from
>> MM 2.1. Also, can you describe what you mean by "automate this".
>
> in MM2.1, if you set the list to moderated and default action to hold
> posting, you can set a some member to be un-moderated (mod bit off) to
> automatically allow their posting. In the web interface of MM2.1 there
> is a checkbox with moderated bit on/off on the member list itself, in
> the postorius interface for MM3 you have to open each members settings
> page to access that. For automation, as list owner, upon registering a
> member (via mass subscription) the possibility to change that ? also
> the me too/dupe setting for example.
>
> Thanks
> _______________________________________________
> Mailman-users mailing list -- mailman-users(a)mailman3.org
> To unsubscribe send an email to mailman-users-leave(a)mailman3.org
> https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/
3 years, 1 month

[MM3-users] Re: Mailman3 without Hyperkitty in docker
by Danil Smirnov
Thank you very much Abhilash!
Could you set up 'latest' tag in postotius repo
<https://hub.docker.com/r/maxking/postorius/tags> please - as it exists for
core/web?
I'd like to have consistent approach across the images...
Also it would be really great to extend image labelling used for
*quay.io/maxking/mailman-*:rolling
<http://quay.io/maxking/mailman-*:rolling>* images to Docker Hub ones...
Version identification is quite hard for Docker...
With my best regards,
Danil
сб, 2 мар. 2019 г. в 03:19, Abhilash Raj <maxking(a)asynchronous.in>:
>
>
> On Thu, Feb 28, 2019, at 10:18 PM, Danil Smirnov wrote:
>
> Hi Abhilash,
>
> Thank you very much - the previous error is fixed now.
>
> But I have another one now, which causes the same 500 Server Error:
>
> bash-4.3# cat /opt/mailman-web-data/logs/uwsgi-error.log
> *** Starting uWSGI 2.0.18 (64bit) on [Fri Mar 1 05:42:09 2019] ***
> compiled with version: 6.3.0 on 01 March 2019 01:52:42
> os: Linux-3.10.0-693.11.1.el7.x86_64 #1 SMP Mon Dec 4 23:52:40 UTC 2017
> nodename: mailman-web
> machine: x86_64
> clock source: unix
> detected number of CPU cores: 2
> current working directory: /opt/mailman-web
> detected binary path: /usr/local/bin/uwsgi
> !!! no internal routing support, rebuild with pcre support !!!
> setgid() to 101
> setuid() to 100
> chdir() to /opt/mailman-web
> your memory page size is 4096 bytes
> detected max file descriptor number: 1048576
> building mime-types dictionary from file /etc/mime.types...1168 entry found
> lock engine: pthread robust mutexes
> thunder lock: disabled (you can enable it with --thunder-lock)
> uwsgi socket 0 bound to TCP address 0.0.0.0:8080 fd 8
> uwsgi socket 1 bound to TCP address 0.0.0.0:8000 fd 9
> Python version: 3.6.8 (default, Jan 30 2019, 23:58:16) [GCC 6.3.0]
> Python main interpreter initialized at 0x55a2df7f57e0
> python threads support enabled
> your server socket listen backlog is limited to 100 connections
> your mercy for graceful operations on workers is 60 seconds
> mapped 166752 bytes (162 KB) for 2 cores
> *** Operational MODE: threaded ***
> Traceback (most recent call last):
> File
> "/usr/local/lib/python3.6/site-packages/django/utils/module_loading.py",
> line 20, in import_string
> return getattr(module, class_name)
> AttributeError: module 'django.contrib.auth.middleware' has no attribute
> 'SessionAuthenticationMiddleware'
>
> The above exception was the direct cause of the following exception:
>
> Traceback (most recent call last):
> File "wsgi.py", line 38, in <module>
> application = get_wsgi_application()
> File "/usr/local/lib/python3.6/site-packages/django/core/wsgi.py", line
> 13, in get_wsgi_application
> return WSGIHandler()
> File
> "/usr/local/lib/python3.6/site-packages/django/core/handlers/wsgi.py", line
> 136, in __init__
> self.load_middleware()
> File
> "/usr/local/lib/python3.6/site-packages/django/core/handlers/base.py", line
> 34, in load_middleware
> middleware = import_string(middleware_path)
> File
> "/usr/local/lib/python3.6/site-packages/django/utils/module_loading.py",
> line 24, in import_string
> ) from err
> ImportError: Module "django.contrib.auth.middleware" does not define a
> "SessionAuthenticationMiddleware" attribute/class
> unable to load app 0 (mountpoint='') (callable not found or import error)
> *** no app loaded. going in full dynamic mode ***
> *** uWSGI is running in multiple interpreter mode ***
> spawned uWSGI master process (pid: 1)
> spawned uWSGI worker 1 (pid: 37, cores: 2)
> --- no python application found, check your startup logs for errors ---
> --- no python application found, check your startup logs for errors ---
> --- no python application found, check your startup logs for errors ---
> --- no python application found, check your startup logs for errors ---
> --- no python application found, check your startup logs for errors ---
> --- no python application found, check your startup logs for errors ---
> --- no python application found, check your startup logs for errors ---
> --- no python application found, check your startup logs for errors ---
> --- no python application found, check your startup logs for errors ---
> --- no python application found, check your startup logs for errors ---
> --- no python application found, check your startup logs for errors ---
> --- no python application found, check your startup logs for errors ---
>
> As per my investigation, this error possibly caused by Django upgrade:
>
> *The SessionAuthenticationMiddleware class is removed. It provided no
> functionality since session authentication is unconditionally enabled in
> Django 1.10.*
>
> See https://docs.djangoproject.com/en/2.0/releases/2.0/
>
> After I've removed the line
>
> https://github.com/maxking/docker-mailman/blob/master/postorius/mailman-web…
> from settings.py, the container is finally working.
>
> I've placed PR in github:
> https://github.com/maxking/docker-mailman/pull/314
>
>
> Thank you for your contributions!
>
> I have merged your pull request and it should now be out (hopefully!).
>
>
> Thank you for your help.
>
> Danil
>
>
> пт, 1 мар. 2019 г. в 04:33, Abhilash Raj <maxking(a)asynchronous.in>:
>
>
>
> On Thu, Feb 28, 2019, at 5:19 PM, Abhilash Raj wrote:
> > On February 27, 2019 11:53:34 PM PST, Danil Smirnov <danil(a)smirnov.la>
> wrote:
> > >Hi Mark,
> > >
> > >Actually all this stuff happens inside the container after it's started
> > >and
> > >initialized without errors. I didn't amend the image anyhow.
> > >
> > >Also I have the configuration based on docker-compose.yaml provided in
> > >the
> > >repository which works just fine for mailman-web image.
> > >
> > >The very same config with postorius image (+ UWSGI_STATIC_MAP param)
> > >fails
> > >with 500 error...
> > >
> > >Now answering your questions:
> > >
> > >ср, 27 февр. 2019 г., 22:56 Mark Sapiro <mark(a)msapiro.net>:
> > >
> > >> do you have django-q in INSTALLED_APPS in your Django settings and
> > >what
> > >> is set for Q_CLUSTER?
> > >>
> > >
> > >I've checked settings.py inside the container and I haven't found any
> > >of
> > >the mentioned configurations there.
> > >
> > >Does the manage.py that's being run here point to the right
> > >settings.py?
> > >>
> > >
> > >No clue.
> > >
> > >Also I wonder why we have some Hyperkitty-related cronjobs in non-HK
> > >configured image?
> > >
> > >
> https://github.com/maxking/docker-mailman/blob/master/postorius/mailman-web…
> >
> > Because I am a dum dum ;-)
> >
> > Will work on removing those crons and stuff. Would be nice if you
> > opened an issue on Github so that I don't forget.
>
> Should now be fixed in the latest image.
>
> >
> > >Danil
> > >
> > >
> > >
> > >> --
> > >> Mark Sapiro <mark(a)msapiro.net> The highway is for gamblers,
> > >> San Francisco Bay Area, California better use your sense - B.
> > >Dylan
> > >> _______________________________________________
> > >> Mailman-users mailing list -- mailman-users(a)mailman3.org
> > >> To unsubscribe send an email to mailman-users-leave(a)mailman3.org
> > >> https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/
> > >>
> > >_______________________________________________
> > >Mailman-users mailing list -- mailman-users(a)mailman3.org
> > >To unsubscribe send an email to mailman-users-leave(a)mailman3.org
> > >https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/
> >
> >
> > --
> > Sent from my Android device with K-9 Mail. Please excuse my brevity.
>
> --
> thanks,
> Abhilash Raj (maxking)
>
>
> --
> thanks,
> Abhilash Raj (maxking)
>
>
>
6 years, 4 months

[MM3-users] Re: HyperKitty async tasks runner: systemd qcluster service fails eventually
by actionmystique@gmail.com
Mark Sapiro wrote:
> Did you replace <django_project_path>, <user> and <group> with
> appropriate values?
Yes, I did, otherwise qcluster service would not be able to start in the first place because it needs to be able to read settings.py (with the proper permissions) which is located in the django project.
> They should be the same thing. Usually manage.py is just configured to
> run the django-admin command for the particular project.
You're right, running either command manually is successful and lead to the same result:
```
<django_project_path># python3 manage.py qcluster
10:49:41 [Q] INFO Q Cluster-1130205 starting.
10:49:41 [Q] INFO Process-1:1 ready for work at 1130235
10:49:41 [Q] INFO Process-1:2 ready for work at 1130236
10:49:41 [Q] INFO Process-1:3 ready for work at 1130237
10:49:41 [Q] INFO Process-1:4 ready for work at 1130238
10:49:41 [Q] INFO Process-1:5 monitoring at 1130239
10:49:41 [Q] INFO Process-1 guarding cluster at 1130234
10:49:41 [Q] INFO Q Cluster-1130205 running.
10:49:41 [Q] INFO Process-1:6 pushing tasks at 1130240
```
If I replace:
```
ExecStart=/usr/bin/django-admin qcluster --pythonpath <django_project_path>
--settings settings
```
with:
```
WorkingDirectory=<django_project_path>
ExecStart=python3 manage.py qcluster
````
I get the same systemd service issue.
If I remove the ``` remote-fs.target``` from ```After=...```, I get the following error:
```
# systemctl daemon-reload
# systemctl restart qcluster
# systemctl status qcluster
● qcluster.service - HyperKitty async tasks runner
Loaded: loaded (/etc/systemd/system/qcluster.service; enabled; vendor preset: enabled)
Active: active (running) since Thu 2019-12-05 11:08:54 CET; 282ms ago
Main PID: 1132324 (python3)
Tasks: 1 (limit: 9284)
Memory: 22.5M
CGroup: /system.slice/qcluster.service
└─1132324 python3 /usr/bin/django-admin qcluster --pythonpath <django_project_path> --settings settings
Dec 05 11:08:54 samsung4-ubuntu django-admin[1132324]: configure_logging(settings.LOGGING_CONFIG, settings.LOGGING)
Dec 05 11:08:54 samsung4-ubuntu django-admin[1132324]: File "/usr/lib/python3/dist-packages/django/utils/log.py", line 76, in configure_logging
Dec 05 11:08:54 samsung4-ubuntu django-admin[1132324]: logging_config_func(logging_settings)
Dec 05 11:08:54 samsung4-ubuntu django-admin[1132324]: File "/usr/lib/python3.7/logging/config.py", line 800, in dictConfig
Dec 05 11:08:54 samsung4-ubuntu django-admin[1132324]: dictConfigClass(config).configure()
Dec 05 11:08:54 samsung4-ubuntu django-admin[1132324]: File "/usr/lib/python3.7/logging/config.py", line 571, in configure
Dec 05 11:08:54 samsung4-ubuntu django-admin[1132324]: '%r' % name) from e
Dec 05 11:08:54 samsung4-ubuntu django-admin[1132324]: ValueError: Unable to configure handler 'file'
Dec 05 11:08:54 samsung4-ubuntu systemd[1]: qcluster.service: Main process exited, code=exited, status=1/FAILURE
Dec 05 11:08:54 samsung4-ubuntu systemd[1]: qcluster.service: Failed with result 'exit-code'.
```
This issue seems related to logging; I configured the following in ```/etc/mailman3/mailman.cfg```:
```
[logging.debian]
format: %(asctime)s (%(process)d) %(message)s
datefmt: %b %d %H:%M:%S %Y
propagate: no
level: debug
path: mailman.log
[logging.root]
level: debug
[logging.archiver]
level: debug
[logging.bounce]
level: debug
[logging.config]
level: debug
[logging.database]
level: debug
[logging.debug]
level: debug
[logging.error]
level: debug
[logging.fromusenet]
level: debug
[logging.http]
level: debug
[logging.locks]
level: debug
[logging.mischief]
level: debug
[logging.plugins]
level: debug
[logging.runner]
level: debug
[logging.smtp]
level: debug
[logging.subscribe]
level: debug
[logging.vette]
level: debug
```
5 years, 6 months

[MM3-users] Re: Confirmation emails to Users has wrong domain name (example.com!)
by Odhiambo Washington
On Thu, Sep 30, 2021 at 1:59 AM Abhilash Raj <maxking(a)asynchronous.in>
wrote:
>
>
> > On Sep 29, 2021, at 2:34 PM, Odhiambo Washington <odhiambo(a)gmail.com>
> wrote:
> >
> > On Wed, Sep 29, 2021 at 8:31 PM Mark Sapiro <mark(a)msapiro.net> wrote:
> >
> >> On 9/29/21 9:50 AM, Odhiambo Washington wrote:
> >>> 1. Confirmation emails to Users has wrong domain name (example.com!)
> >>> <https://docs.mailman3.org/en/latest/faq.html#id1>
> >>> <
> >>
> https://docs.mailman3.org/en/latest/faq.html#confirmation-emails-to-users-h…
> >>>
> >>>
> >>> This happens when your reverse (SSL) proxy isn’t setting up the correct
> >>> headers when proxying requests. Fix this by setting the right
> >>> proxy_set_header directives:
> >> ...
> >>> How is this supposed to be mitigated in Apache when using WSGI?
> >>>
> >>> My config:
> >>>
> >>> WSGIDaemonProcess hyperkitty threads=25 python-path=/usr/local/mailman
> >>> user=mailman group=mailman
> >>> WSGIPythonHome "/usr/local"
> >>> WSGIProcessGroup hyperkitty
> >>
> >>
> >> You are using mod_wsgi and not proxying at all, so this is not relevant
> >> in your case.
> >>
> >> Are you actually seeing this issue? If so, it might be related to
> >>
> >>
> https://docs.mailman3.org/en/latest/faq.html#the-domain-name-displayed-in-h…
> >>
> >
> > My issue is related to this, but the documentation referred to is not for
> > the faint-hearted!
> > I can't make head or tails of it.
>
> Click on “Domain” in Postorius from the top bar, which should take you to
> the Domains page.
>
> For your domain (in the “Mail Host” column), see the corresponding “Web
> Host” column, it should look something like:
>
> lists.mailman3.org (lists.mailman3.org)
> (Edit)
> SITE_ID = 1
>
Mine looks different, slightly. But there is no example.com at all.
[image: Abhilash.png]
>
> on a new-ish version of Postorius.
>
I have the newest versions of everything, having installed only yesterday.
>
> If it doesn’t show the right values and instead shows “example.com” for
> you, click on the “Edit” link, which will take
> you to a page that will allow you to edit both the values.
>
It shows the right values, but with "SITE_ID = 2". In my settings_local.py
I have SITE_ID = 1.
I suppose the example.com is the one tied to SITE_ID = 1 and that is what I
have in my settings_local.py.
Should I edit my settings_local.py?
I am still confused.
--
Best regards,
Odhiambo WASHINGTON,
Nairobi,KE
+254 7 3200 0004/+254 7 2274 3223
"Oh, the cruft.", egrep -v '^$|^.*#' :-)
3 years, 9 months

[MM3-users] Re: possible backscatter attack using Mailman3 servers
by Odhiambo Washington
On Sat, Jan 4, 2025 at 5:30 AM David Newman <dnewman(a)networktest.com> wrote:
>
>
> On 1/3/25 5:44 PM, Mark Sapiro wrote:
>
> >> Greetings. On a system running Mailman 3.3.9 and Postfix, I'm seeing
> >> about 20-30 entries per day in the Postfix queue where it appears a
> >> Gmail user signs up for a mailing list that requires confirmation, and
> >> Gmail responds that the user is too busy to handle requests.
> >>
> >> There are no publicly advertised email lists on this server, and I
> >> don't ever see anything in the Mailman logs indicating the user ever
> >> tried signing up.
> >
> >
> > This is an attack mail bombing the user. The requests that result in the
> > can come via web or email. Mailman's logging of subscribes has been
> > missing most events through Mailman 3.3.10. See https://gitlab.com/
> > mailman/mailman/-/issues/1143 which will be fixed in 3.3.11, but
> > subscribes waiting user confirmation still won't be logged.
> >
> > However, the message with subject "Please Confirm Your Email Address"
> > comes from Django allauth so it isn't actually Mailman sending it but
> > rather Django allauth as a result of a request to sign up for a Django
> > account at https://mail.example3.com/accounts/signup/. You can probably
> > find that request in your web server logs, and you may find the user
> > and/or email in the Django admin UI.
>
> Thanks VERY much for this.
>
> No such users in the Django UI, but the web server logs have 252
> attempts from 132 unique IPv4 addresses registered to different ISPs
> throughout Europe.
>
> So, even though Mailman support for more detailed logging of sub and
> unsub requests would be useful, it likely would not have helped with
> attacks from many source IP addresses.
>
> >
> > Since django-mailman3 1.3.6, you can disable these signups by putting
> >
> > ACCOUNT_ADAPTER =
> 'django_mailman3.views.user_adapter.DisableSignupAdapter'
> >
> > in your Django settings, but then your users won't be able to sign up
> > for web accounts.
>
> I have made this change. As for not having web accounts, this just means
> new users cannot sign up to manage their Mailman settings, correct? I
> presume existing web accounts will continue to work.
>
You could also try this:
https://lists.mailman3.org/archives/list/mailman-users@mailman3.org/message…
It really helped in many cases, although with the change you already made,
it becomes a useless effort.
--
Best regards,
Odhiambo WASHINGTON,
Nairobi,KE
+254 7 3200 0004/+254 7 2274 3223
In an Internet failure case, the #1 suspect is a constant: DNS.
"Oh, the cruft.", egrep -v '^$|^.*#' ¯\_(ツ)_/¯ :-)
[How to ask smart questions:
http://www.catb.org/~esr/faqs/smart-questions.html]
5 months, 4 weeks

[MM3-users] Re: Splitting hosts: mta&core vs postorius
by Ruth Ivimey-Cook
Mark,
Thank you for your thoughts so far.
On 6/23/20 3:22 PM, Mark Sapiro wrote:
> I have done further testing. See my comment at
> <https://gitlab.com/mailman/mailman/-/issues/735#note_366074014>.
>
> You need to set hostname: in mailman.cfg to the actual external IP
> address of the Mailman host machine or to a name which resolves to that
> IP both internally and externally, and also set that host name/IP in the
> MAILMAN_REST_API_URL setting on the Postorius machine.
I've done that, but there is no observed change in the browser (still
get same 404 error).
Specifically, I reset hostname to be a newly-added CNAME of the actual
host address, and ensured that the 0.0.0.0 addresses were no longer there.
>
>> However I then get another issue. From the mailman.log file I now see in
>> the last few lines. For clarity I've numbered them like this "{1}":
>>
>> {1} [22/Jun/2020:00:58:24 +0000] "GET /3.1/domains HTTP/1.1" 200 320 "-"
>> "GNU Mailman REST client v3.3.1"
>> {2} [22/Jun/2020:00:58:24 +0000] "GET /3.1/domains/ch-bc.org.uk
>> HTTP/1.1" 200 215 "-" "GNU Mailman REST client v3.3.1"
>> {3} [22/Jun/2020:00:58:24 +0000] "GET
>> /3.1/domains/greyarea-web1.cam.ivimey.org/lists?advertised=true&count=0&page=1
>> HTTP/1.1" 404 26 "-" "GNU Mailman REST client v3.3.1"
>>
>> At this point the browser screen reports "Something went wrong" and the
>> message "HTTP Error 404: {"title": "404 Not Found"}"
> Make the above changes and see if that solves this. If not, let us know
> and we'll try to help.
A tcpdump now shows the GET of
/3.1/domains/mailman-web.ivimey.org/lists&advertised=true&count=0&page=1
directed at mailman-core and the reply being 404 not found.
The extract from core's mailman.log is now:
[24/Jun/2020:20:41:11 +0000] "GET
/3.1/domains/mailman-web.ivimey.org/lists?advertised=true&count=0&page=1
HTTP/1.1" 404 26 "-" "GNU Mailman REST client v3.3.1"
And the entry for postorius in mailmansuite.log:
ERROR 2020-06-24 21:41:11,191 13310 postorius Un-handled exception:
HTTP Error 404: {"title": "404 Not Found"}
Traceback (most recent call last):
File
"/opt/mailman3/lib/python3.6/site-packages/django/core/handlers/base.py",
line 113, in _get_response
response = wrapped_callback(request, *callback_args,
**callback_kwargs)
[snip]
File
"/opt/mailman3/lib/python3.6/site-packages/mailmanclient/restbase/page.py",
line 37, in __init__
self._create_page()
File
"/opt/mailman3/lib/python3.6/site-packages/mailmanclient/restbase/page.py",
line 62, in _create_page
response, content = self._connection.call(self._build_url())
File
"/opt/mailman3/lib/python3.6/site-packages/mailmanclient/restbase/connection.py",
line 116, in call
error_msg, response, None)
urllib.error.HTTPError: HTTP Error 404: {"title": "404 Not Found"}
Note that the mailman-web.ivimey.org address is the newly-added CNAME of
greyarea-web1, mailman-core is likewise the CNAME of greyarea-post.
There is nothing I can see in the other logs that looks out of the ordinary.
I guess this indicates that my earlier wondering if I had something left
over from a past install is dispelled, as that name didn't exist until
today.
5 years

[MM3-users] Re: hyperkitty_import Unicode Errors
by kdhall@binghamton.edu
Stephen J Turnbull wrote:
> On 2023-05-07 07:39 Mark Sapiro writes:
> > On 5/6/23 11:27, Dave Hall via Mailman-users wrote:
> > > django.db.utils.OperationalError: (1366, "Incorrect string value:
> > '\xE1\x90\xA7\x0A\x0AO...' for column
> > mailman3web.hyperkitty_email.content at row 1")
> > Is there a known cause for this?
> > Almost always nonconforming user clients. You write "frequently", but
> I'm
> guessing it's maybe 1% or 2% of all the messages, right? I suspect it's
> a
> particular author or institution using such a client.
> > Is it fixed in some release more recent than 0+20180916?
> > This is almost surely not something we can fix. Based on the error,
> it's in third
> party code (Django) that we import. It's possible we could provide a
> more explanatory message, but the only thing we can sensibly do is hold
> the
> message for an admin to edit it by hand. As long as the text in
> question and the
> Content-Type header aren't too sensitive, we can help with identifying
> charset
> (often UTF-8 as Mark suggests but why someone would be encoding FINAL
> MIDDLE DOT is a mystery to me).
> > I'm not sure what's going on here. My first thought is the database is
> > MySQL or MariaDB and this is a 4-byte UTF-8 encoding and the database
> > column charset definition is utf8 and not utf8mb4, but
> > '\xE1\x90\xA7\x0A\x0A' is the 3-byte UTF-8 encoding for CANADIAN
> > SYLLABICS FINAL MIDDLE DOT ('\xE1\x90\xA7') followed by two
> > newlines. so I'm not sure what the issue is.
> > I'm guessing home-made client, possibly Asian or a spammer, which
> provides no
> content-type header. Even today I see raw 8-bit encoded text without an
> encoding
> spec from legitimate Japanese and Chinese sources, and of course with
> spammers
> all bets are off -- they might even do it deliberately to crash filters.
I have located an email with a similar error in a V2.1 .mbox file. The post was by a faculty member in my organization using Thunderbird 60.2.1 on a Mac - OSX 10.13. The list was used to correspond with students taking a programming course.
The message body is multi-part MIME with two sections:
This is a multi-part message in MIME format.
--------------4BAB6CD38F4927471D366565
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Transfer-Encoding: 8bit
and
--------------4BAB6CD38F4927471D366565
Content-Type: text/html; charset=utf-8
Content-Transfer-Encoding: 8bit
The hexadecimal sting \\xEF\\xBB\\xBF\\xEF\\xBB\\xBF appears one place in each section.
I'm not sure exactly what this means. I did check my MariaDB (as Mark hinted) and found that it set for utf8 rather than utf8mb4. I'd be willing to change this, but would I also have to do something to update the Mailman databases since those tables are already created?
Thanks.
-Dave
2 years, 1 month

[MM3-users] Re: mail loops back to myself
by Florian Sukup
On 6/13/25 01:58, Mark Sapiro wrote:
> On 6/12/25 15:05, Florian Sukup wrote:
>>
>> I always restart mailman3 after changing main.cf
>
> I asked if you restarted/reloaded Postfix. I would assume that you had,
Sorry, I meant postfix which I restart after changing main.cf or master.cf.
> but I'm at a loss to understand the issue, unless your
> /etc/postfix/master.cf is missing an uncommented entry for lmtp like
> ```
> lmtp unix - - y - - lmtp
> ```
>
I found it there, here is my master.cf:
vvvvvvvvvvvvvvvvvvvvvvvvvvvvvv
smtp inet n - y - - smtpd
submission inet n - y - - smtpd
-o syslog_name=postfix/submission
-o smtpd_tls_security_level=encrypt
-o smtpd_sasl_auth_enable=yes
-o smtpd_sasl_type=dovecot
-o smtpd_sasl_path=private/auth
-o smtpd_tls_auth_only=yes
-o smtpd_reject_unlisted_recipient=no
pickup unix n - y 60 1 pickup
cleanup unix n - y - 0 cleanup
qmgr unix n - n 300 1 qmgr
tlsmgr unix - - y 1000? 1 tlsmgr
rewrite unix - - y - - trivial-rewrite
bounce unix - - y - 0 bounce
defer unix - - y - 0 bounce
trace unix - - y - 0 bounce
verify unix - - y - 1 verify
flush unix n - y 1000? 0 flush
proxymap unix - - n - - proxymap
proxywrite unix - - n - 1 proxymap
smtp unix - - y - - smtp
relay unix - - y - - smtp
-o syslog_name=postfix/$service_name
showq unix n - y - - showq
error unix - - y - - error
retry unix - - y - - error
discard unix - - y - - discard
local unix - n n - - local
virtual unix - n n - - virtual
lmtp unix - - y - - lmtp
anvil unix - - y - 1 anvil
scache unix - - y - 1 scache
postlog unix-dgram n - n - 1 postlogd
maildrop unix - n n - - pipe
flags=DRXhu user=vmail argv=/usr/bin/maildrop -d ${recipient}
uucp unix - n n - - pipe
flags=Fqhu user=uucp argv=uux -r -n -z -a$sender - $nexthop!rmail
($recipient)
ifmail unix - n n - - pipe
flags=F user=ftn argv=/usr/lib/ifmail/ifmail -r $nexthop ($recipient)
bsmtp unix - n n - - pipe
flags=Fq. user=bsmtp argv=/usr/lib/bsmtp/bsmtp -t$nexthop -f$sender
$recipient
scalemail-backend unix - n n - 2 pipe
flags=R user=scalemail argv=/usr/lib/scalemail/bin/scalemail-store
${nexthop} ${user} ${extension}
mailman unix - n n - - pipe
flags=FRX user=list argv=/usr/lib/mailman/bin/postfix-to-mailman.py
${nexthop} ${user}
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Is the last line a problem? It seems to be from mailman2.
Is there a possibility to debug in more detail? To find out when and
where it takes the wrong turn?
The system running has grown over many years and even if the hardware
changed the configuration was kept. So there may a flaw outside the
postfix/mailman configuration which causes the error, ie. network
configuration.
Another thing I can do is to upgrade from bullseye to bookworm. Which I
haven't done yet because I was with mailman2/sendmail. That's the reason
to change to mailman3/postfix. Since, mailman2 doesn't work anymore I
could do it and hope for a miracle ... . This would mean postfix 3.5.25
-> 3.7.11 and mailman3 3.3.3 -> 3.3.8 . That's more an act of desperation.
Thanks for your help,
Florian.
2 weeks, 5 days

[MM3-users] Re: Docker, Mailman 3, templates and list user accounts
by Abhilash Raj
Hi,
On Mon, Aug 7, 2017, at 06:06 AM, Henrik Rasmussen wrote:
> I used Docker to installed Mailman 3.
>
> The top header of the web interface says "Example.Com" while linking to
> the correct site URL (I believe coming from SERVE_FROM_DOMAIN). In a
> post[1], Mark Sapiro referred to the template system in Mailman 3 by
> pointing out that "a custom template can be put in
> var/templates/site/en/welcome.txt or
> var/templates/domains/example.com/en/welcome.txt<http://var/templates/domains/example.com/en/welcome.txt>
> or
> var/templates/lists/listname.example.com/en/welcome.txt<http://var/templates/lists/listname.example.com/en/welcome.txt>
> where var is Mailman's configured var_dir". I believe this refers to the
> mail templates.
Yes, these are email templates.
>
> 1) Where do I change the similar template system, for the web
> interface, without breaking a laver upgrade?
I am not sure if you can do that for now without tinkering with the
source code.
> 2) How do I change the site name in the top of the web interface on
> Mailman 3 to my subside and ?
When you deploy the web interface, the domain it is being served from is
used at the top of the web interface. It is defined by SITE_ID in the
settings.py file for Django (or settings_local.py if you are using the
container images). The default value is set to 1 and points to
example.com.
In the newer versions of Container Images, the SERVE_FROM_DOMAIN
environment variable's value will replace the `example.com` domain and
you will be able to see that instead of example.com.
For now, you should just login into the admin interface at /admin/ and
just create a new Site model. And then use the id of that Site in your
Django's settings.py. Each domain that you add gets their own id and
depending on which domain you are serving from, you can set the SITE_ID
in the settings. Mailman 3 supports multiple domains at the same time.
> [1]
> https://lists.mailman3.org/archives/list/mailman-users@mailman3.org/thread/…
>
>
>
> The Mailman command in Mailman Core doesn't seem to have a command for
> listing the accounts users have created by using Sign up in the web
> interface, so I believe that accounts may be created in the webinterface.
The Core and and Web frontend handle users separately. Ideally, a user
shouldn't have to worry about the Core ever and only interact with the
Web Interface.
> Is there similar commands for the web interface like the mailman commands
> for the Mailman core?
You can interact with the Django shell to get almost any internal data
structure. But you can go to the admin interface at /admin/ and you will
find the list of users there along with a whole lot of other
information.
>
> Regards, Henrik Rasmussen
> _______________________________________________
> Mailman-users mailing list
> mailman-users(a)mailman3.org
> https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/
--
thanks,
Abhilash Raj
7 years, 10 months

[MM3-users] The msgtext argument in 'self._connection.sendmail(envsender, recipients, msgtext)' is supposed to be a string containing only ascii characters.
by Henrik Rasmussen
Hi Mark.
This was originally from another thread https://lists.mailman3.org/archives/list/mailman-users@mailman3.org/message…, but as it isn't related to the problem in the thread, I'll split it in another thread.
On 09/29/2017 05:46 AM Mark Sapiro wrote:
>> In addition, the log contains other trace backs that might or might not associate to this problem:
>>
>> Sep 24 21:11:27 2017 (34) Uncaught runner exception: 'ascii' codec can't encode character '\udcea' in position 3093: ordinal not in range(128)
>> Sep 24 21:11:28 2017 (34) Traceback (most recent call last):
>> File "/usr/local/lib/python3.6/site-packages/mailman/core/runner.py", line 171, in _one_iteration
>> self._process_one_file(msg, msgdata)
>> File "/usr/local/lib/python3.6/site-packages/mailman/core/runner.py", line 264, in _process_one_file
>> keepqueued = self._dispose(mlist, msg, msgdata)
>> File "/usr/local/lib/python3.6/site-packages/mailman/runners/outgoing.py", line 93, in _dispose
>> self._func(mlist, msg, msgdata)
>> File "/usr/local/lib/python3.6/site-packages/mailman/mta/deliver.py", line 86, in deliver
>> refused = agent.deliver(mlist, msg, msgdata)
>> File "/usr/local/lib/python3.6/site-packages/mailman/mta/bulk.py", line 101, in deliver
>> mlist, msg, msgdata, recipients)
>> File "/usr/local/lib/python3.6/site-packages/mailman/mta/base.py", line 70, in _deliver_to_recipients
>> sender, sorted(recipients), msg.as_string())
>> File "/usr/local/lib/python3.6/site-packages/mailman/mta/connection.py", line 84, in sendmail
>> results = self._connection.sendmail(envsender, recipients, msgtext)
>> File "/usr/local/lib/python3.6/smtplib.py", line 855, in sendmail
>> msg = _fix_eols(msg).encode('ascii')
>> UnicodeEncodeError: 'ascii' codec can't encode character '\udcea' in position 3093: ordinal not in range(128)
>> Sep 24 21:11:28 2017 (34) SHUNTING: 1506287488.0529234+cbf8a31cad265a40a18e8955be0c9ad8b48a1b66
>
>
> This may be a bug. The msgtext argument in
> 'self._connection.sendmail(envsender, recipients, msgtext)' is supposed
> to be a string containing only ascii characters. I'm interested in
> what's in Mailman's
> var/queue/shunt/1506287488.0529234+cbf8a31cad265a40a18e8955be0c9ad8b48a1b66.pck.
> You may be able to print the contents with Mailman's
>
> bin/mailman queue
> var/queue/shunt/1506287488.0529234+cbf8a31cad265a40a18e8955be0c9ad8b48a1b66.pck
>
> There shouldn't be raw unicodes like \udcea in the text of the message,
> but we should defend against that anyway.
[root@lstapp01pl ~]# docker exec -it mailman-core mailman qfile var/queue/shunt/1506287488.0529234+cbf8a31cad265a40a18e8955be0c9ad8b48a1b66.pck
[----- start pickle -----]
<----- start object 1 ----->
Traceback (most recent call last):
File "/usr/local/bin/mailman", line 11, in <module>
sys.exit(main())
File "/usr/local/lib/python3.6/site-packages/mailman/bin/mailman.py", line 100, in main
args.func(args)
File "/usr/local/lib/python3.6/site-packages/mailman/commands/cli_qfile.py", line 81, in process
printer.pprint(obj)
File "/usr/local/lib/python3.6/pprint.py", line 139, in pprint
self._format(object, self._stream, 0, 0, {}, 0)
File "/usr/local/lib/python3.6/pprint.py", line 176, in _format
stream.write(rep)
UnicodeEncodeError: 'utf-8' codec can't encode character '\udcea' in position 3025: surrogates not allowed
--
Henrik Rasmussen <her(a)adm.ku.dk>
University of Copenhagen, Danmark
7 years, 8 months

[MM3-users] error changed after restart (was: KeyError: 'get_requests_count' after an upgrade)
by Guillermo Hernandez (Oldno7)
I restarted de server and the error changed. Now the log shows
"KeyError: 'subscription_mode'":
ERROR 2021-02-06 11:47:49,015 26798 django.request Internal Server
Error: /mailman3/mailman3/lists/name_and_domain.of.the.list
Traceback (most recent call last):
File
"/usr/local/lib/python3.7/site-packages/mailmanclient/restbase/base.py",
line 119, in __getattr__
return self._get(name)
File
"/usr/local/lib/python3.7/site-packages/mailmanclient/restbase/base.py",
line 86, in _get
raise KeyError(key)
KeyError: 'subscription_mode'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File
"/usr/local/lib/python3.7/site-packages/django/core/handlers/exception.py",
line 34, in inner
response = get_response(request)
File
"/usr/local/lib/python3.7/site-packages/django/core/handlers/base.py",
line 115, in _get_response
response = self.process_exception_by_middleware(e, request)
File
"/usr/local/lib/python3.7/site-packages/django/core/handlers/base.py",
line 113, in _get_response
response = wrapped_callback(request, *callback_args, **callback_kwargs)
File
"/usr/local/lib/python3.7/site-packages/django/views/generic/base.py",
line 71, in view
return self.dispatch(request, *args, **kwargs)
File
"/usr/local/lib/python3.7/site-packages/postorius/views/generic.py",
line 74, in dispatch
return super(MailingListView, self).dispatch(request, *args, **kwargs)
File
"/usr/local/lib/python3.7/site-packages/django/views/generic/base.py",
line 97, in dispatch
return handler(request, *args, **kwargs)
File
"/usr/local/lib/python3.7/site-packages/postorius/views/list.py", line
295, in get
member.subscription_mode ==
File
"/usr/local/lib/python3.7/site-packages/mailmanclient/restbase/base.py",
line 124, in __getattr__
self.__class__.__name__, name))
AttributeError: 'Member' object has no attribute 'subscription_mode'
***********************
some info about the installed versions via pip list:
pip list | grep django
django-allauth 0.44.0
django-appconf 1.0.4
django-compressor 2.4
django-extensions 3.1.0
django-gravatar2 1.4.4
django-haystack 3.0
django-mailman3 1.3.5
django-picklefield 3.0.1
django-q 1.3.4
djangorestframework 3.12.2
pip list | grep mailman
django-mailman3 1.3.5
mailman 3.3.3
mailman-hyperkitty 1.1.0
mailmanclient 3.3.2
pip list | grep postorius
postorius 1.3.4
On 6/2/21 11:12, Guillermo Hernandez (Oldno7) via Mailman-users wrote:
> I've just upgrade mailman 3 installation following Mr. Sapiro advice:
> did a
>
> pip install --upgrade django-mailman3 hyperkitty mailman mailmanclient
> mailman-hyperkitty postorius
>
> I did a "python3 manage.py migrate" after, too.
>
> And all seemed to run well.
>
> All the lists showed in postorius via web, but when I try to accesss
> into one of them the browser shows an error.
>
> In the log you can see:
>
> *-*-*-*-*-*-*
>
> Traceback (most recent call last):
> File
> "/usr/local/lib/python3.7/site-packages/mailmanclient/restbase/base.py",
> line 119, in __getattr__
> return self._get(name)
> File
> "/usr/local/lib/python3.7/site-packages/mailmanclient/restbase/base.py",
> line 86, in _get
> raise KeyError(key)
> KeyError: 'get_requests_count'
>
> ... (And after all the traceback lines)
>
> AttributeError: 'MailingList' object has no attribute
> 'get_requests_count'
>
> *-*-*-*-*-*-*-*
>
> The lists seem to be distributing messeages well.. but I cannot acces
> via web administration (django/postorius)
>
> Can anyone point me in the right direction to solve this, please?
>
> _______________________________________________
> Mailman-users mailing list -- mailman-users(a)mailman3.org
> To unsubscribe send an email to mailman-users-leave(a)mailman3.org
> https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/
>
4 years, 4 months

[MM3-users] Re: All addresses in a bounced list posting seem to be considered as bouncing
by Andy Smith
Hi Mark,
On Sat, Jul 09, 2022 at 09:06:55AM -0700, Mark Sapiro wrote:
> I can't explain what happened in your case. It seems that somehow the
> original post was delivered to the -bounces address and parsed by one of the
> heuristic recognizers (probably simplematch), but how could that happen?
This seems to have been the DSN that caused that bounce score (Exim
mainlog):
2022-07-09 12:46:13 1oA9qf-007qVv-2R <= <> R=1oA9qc-007qOx-0T U=Debian-exim P=local S=44941
2022-07-09 12:46:13 1oA9qf-007qVv-2R => users-bounces(a)mailman.bitfolk.com R=mailman3_router T=mailman3_transport H=127.0.0.1 [127.0.0.1] C="250 Ok"
2022-07-09 12:46:13 1oA9qf-007qVv-2R Completed
The P=local is a local submission, so I think that was generated by
Mailman in response to the SMTP reject.
In the smtp.log, mail from list poster came in:
Jul 09 12:46:04 2022 (71509) ('127.0.0.1', 45530) handling connection
Jul 09 12:46:04 2022 (71509) ('127.0.0.1', 45530) Data: b'LHLO lists0.bitfolk.com'
Jul 09 12:46:04 2022 (71509) ('127.0.0.1', 45530) Data: b'MAIL FROM:<xxxxx(a)xxxxx.com>'
Jul 09 12:46:04 2022 (71509) ('127.0.0.1', 45530) sender: xxxxx(a)xxxxx.com
Jul 09 12:46:04 2022 (71509) ('127.0.0.1', 45530) Data: b'RCPT TO:<users(a)mailman.bitfolk.com>'
Jul 09 12:46:04 2022 (71509) ('127.0.0.1', 45530) recip: users(a)mailman.bitfolk.com
Jul 09 12:46:04 2022 (71509) ('127.0.0.1', 45530) Data: b'DATA'
Jul 09 12:46:04 2022 (71509) ('127.0.0.1', 45530) Data: b'QUIT'
Jul 09 12:46:04 2022 (71509) ('127.0.0.1', 45530) connection lost
Jul 09 12:46:04 2022 (71509) Connection lost during _handle_client()
Over in Exim's mainlog I then see that delivered out to list
members. One of them rejects it at SMTP time, which I think causes
this:
Jul 09 12:46:13 2022 (71509) Available AUTH mechanisms: LOGIN(builtin) PLAIN(builtin)
Jul 09 12:46:13 2022 (71509) Peer: ('127.0.0.1', 35440)
Jul 09 12:46:13 2022 (71509) ('127.0.0.1', 35440) handling connection
Jul 09 12:46:13 2022 (71509) ('127.0.0.1', 35440) Data: b'LHLO lists0.bitfolk.com'
Jul 09 12:46:13 2022 (71509) ('127.0.0.1', 35440) Data: b'MAIL FROM:<>'
Jul 09 12:46:13 2022 (71509) ('127.0.0.1', 35440) sender: <>
Jul 09 12:46:13 2022 (71509) ('127.0.0.1', 35440) Data: b'RCPT TO:<users-bounces(a)mailman.bitfolk.com>'
Jul 09 12:46:13 2022 (71509) ('127.0.0.1', 35440) recip: users-bounces(a)mailman.bitfolk.com
Jul 09 12:46:13 2022 (71509) ('127.0.0.1', 35440) Data: b'DATA'
Jul 09 12:46:13 2022 (71509) ('127.0.0.1', 35440) Data: b'QUIT'
Jul 09 12:46:13 2022 (71509) ('127.0.0.1', 35440) connection lost
Jul 09 12:46:13 2022 (71509) Connection lost during _handle_client()
…and I think that bounce message somehow incremented the bounce
score for andy(a)bitfolk.com even though that address was only present
in the original post's Cc: and body.
Is there a good way to further debug this? Maybe by being able to
see the full content of the DSNs that Mailman generates?
I think I've seen this before in the last couple of weeks so I'm
sure it'll crop up again soon. I've seen it mention about bounce
score for users-leave before, but I only really paid attention today
when it also listed my own address.
Thanks,
Andy
2 years, 11 months

[MM3-users] Re: MM3 templates
by Odhiambo Washington
On Wed, Feb 15, 2023 at 7:26 PM Mark Sapiro <mark(a)msapiro.net> wrote:
> On 2/15/23 08:09, Odhiambo Washington wrote:
> >
> > [18:47 ~ ]$ ls -al /opt/mailman/mm/var/templates/lists/
> kictanet.lists.kictanet.or.ke/en/
> > total 48
> > drwxr-xr-x 2 mailman mailman 512 Feb 14 08:53 .
> > drwxr-xr-x 3 mailman mailman 512 Feb 14 08:54 ..
> > -rw------- 1 mailman mailman 615 Jan 17 13:57
> domain:admin:notice:new-list.txt
>
> This template is used in a domain context. It will never be accessed
> here. It needs to be in /opt/mailman/mm/var/templates/site/en/ or
> /opt/mailman/mm/var/templates/domains/lists.kictanet.or.ke/en/
The last time I referred to the link, I deliberately duplicated the <LC>
folder in two locations:
[09:51 ~ ]$ ls -al /opt/mailman/mm/var/templates/site/en/
total 48
drwxr-xr-x 2 mailman mailman 512 Feb 14 08:53 .
drwxr-xr-x 3 mailman mailman 512 Feb 14 08:53 ..
-rw------- 1 mailman mailman 615 Jan 17 13:57
domain:admin:notice:new-list.txt
-rw------- 1 mailman mailman 341 Jan 17 13:54 list:admin:action:post.txt
-rw------- 1 mailman mailman 158 Dec 17 13:32
list:member:digest:footer.txt
-rw------- 1 mailman mailman 452 Jan 17 13:54
list:member:digest:masthead.txt
-rw------- 1 mailman mailman 137 Jan 17 13:55
list:member:generic:footer.txt
-rw------- 1 mailman mailman 1219 Dec 8 15:12
list:member:regular:footer.txt
-rw------- 1 mailman mailman 944 Jan 17 15:50
list:user:action:subscribe.txt
-rw------- 1 mailman mailman 247 Jan 17 13:56 list:user:notice:post.txt
-rw------- 1 mailman mailman 802 Jan 17 13:56 list:user:notice:probe.txt
-rw------- 1 mailman mailman 639 Jan 17 13:57
list:user:notice:welcome.txt
Yet, it is NOT being picked. So definitely something is wrong somewhere.
> > -rw------- 1 mailman mailman 341 Jan 17 13:54
> list:admin:action:post.txt
> > -rw------- 1 mailman mailman 158 Dec 17 13:32
> list:member:digest:footer.txt
> > -rw------- 1 mailman mailman 452 Jan 17 13:54
> list:member:digest:masthead.txt
> > -rw------- 1 mailman mailman 137 Jan 17 13:55
> list:member:generic:footer.txt
>
> The generic footer is used for both regular messages and digests if
> there isn't a specific regular or digest footer. In this case, you have
> both so the generic footer won't ever be used.
>
Thank you for clarifying that. I actually will delete the generic footer in
this case because I don't need it.
> > -rw------- 1 mailman mailman 1219 Dec 8 15:12
> list:member:regular:footer.txt
> > -rw------- 1 mailman mailman 944 Jan 17 15:50
> list:user:action:subscribe.txt
> > -rw------- 1 mailman mailman 247 Jan 17 13:56
> list:user:notice:post.txt
> > -rw------- 1 mailman mailman 802 Jan 17 13:56
> list:user:notice:probe.txt
> > -rw------- 1 mailman mailman 639 Jan 17 13:57
> list:user:notice:welcome.txt
>
> Are the other templates such as list:member:regular:footer.txt used?
>
I do see that in posts to the list, but I believe that is perhaps only
working because the list had that footer when it was imported from MM2.
--
Best regards,
Odhiambo WASHINGTON,
Nairobi,KE
+254 7 3200 0004/+254 7 2274 3223
"Oh, the cruft.", egrep -v '^$|^.*#' ¯\_(ツ)_/¯ :-)
2 years, 4 months

[MM3-users] Re: spanish localization
by Victoriano Giralt
El sáb, 13-02-2021 a las 20:52 +0100, Guillermo Hernandez (Oldno7) via
Mailman-users escribió:
> On 13/2/21 20:00, Mark Sapiro wrote:
> > On 2/13/21 2:33 AM, Guillermo Hernandez (Oldno7) via Mailman-users
> > wrote:
> > > But... here is a thing that I can not understand: If the source (the
> > > .po
> > > file) is from november 7th, it doesn't matter how many times you
> > > recompile it: the result will be the same.
> > Correct, but the point is if you download the latest
> > gnu-mailman-mailman-es.po from weblate, and compare it to the Nov 7
> > file
> > in the distribution, you will find they are identical, so it it appears
> > that the weblate translation hasn't changed since that time.
> >
> > If there are issues in this mailman.po, they exist in weblate too and
> > need to be fixed there.
>
> That clarifies all. Thanks. As I said in my previous message, I'll wait
> for the next upgrade and hopingly the translations done after 7h of
> november (by others and me) will be there.
I've visited Weblate, all Spanish strings are translated. Spanish is 100%
translated, but, none of them have been "approved", whatever that is. It
seems that a reviewer needs to approve the translation in order for them to
be incorporated or released or whatever. I was sure I had reviewed
everything between November 7th and the day Abhilash announced the release
candidate and asked for translation review, but nothing has made it to the
released version.
Maybe there's something in the translation flow that we are doing wrong.
I'm starting to miss the good old days when Mailman 2 translators just
downloaded the .po files and returned them :-)
> > Also note that the translations on weblate only affect strings in the
> > core code. The Mailman core templates are not currently translated in
> > weblate and there are currently no Spanish language templates. One
> > would
> > need to create Spanish translations of all the templates in
> > <
> > https://gitlab.com/mailman/mailman/-/tree/master/src/mailman/templates/en
> > >
> > and submit a merge request to add them to a mailman/templates/es/
> > directory.
> >
> I will make the template translations locally, test them, and then, if
> they are yet lacking in the main repo, follow your suggestion.
I'm a bit short on time, but I'll help Guillermo with that, at least
reviewing or doing a second pass. I'm not proficient enough to speak about
Mailman core templates, but for Django templates, there is a nice tag for
marking text with translations in the .mo files ...
--
Victoriano Giralt Innovation Director
Digital Transformation Vicerectorate University of Malaga
+34952131415 SPAIN
==================================================================
Note: signature.asc is the electronic signature of present message
A: Yes.
> Q: Are you sure ?
>> A: Because it reverses the logical flow of conversation.
>>> Q: Why is top posting annoying in email ?
4 years, 4 months

[MM3-users] Re: only show mail domains from web host on web-host-url
by Abhilash Raj
> On Mar 19, 2021, at 6:38 AM, Jens Günther <jens.guenther(a)posteo.de> wrote:
>
> Thank you for your answer. I should have seen that in the Docs, but somehow missed it: https://docs.mailman3.org/en/new/prodsetup.html
You seem to have landed on a very old version of the docs that I didn’t unfortunately knew
was even available. I have disabled that page now.
The settings are documented in https://docs.mailman3.org/en/latest/config-web.html
>
> I set it in the corresponding file, but unfortunately it doesn't work :-( I tried other setting to prove, that the file is used (ALLOWED_HOSTS works, changed here from '*' to 'localhost' and my example-domains, this works). It seems to be the same as this user describes (a while ago): https://lists.mailman3.org/archives/list/mailman-users@mailman3.org/thread/…
>
> How could I check, that the setting is used!?
>
> But maybe some additional information:
> - I use the Debian installation on a stable buster, so mailman is version 3.2.1
> - I use apache2 as my web-server and use the given alias-conf-file
> - Python is version 3.7.3
> - Postorius is Version 1.2.4
> - HyperKitty is version 1.2.2
>
> -> In Django admin-Panel (/mailman3/admin/) I added 2 Websites test1.xyz.de and test2.xyz.de
> -> In Postorius (/mailman3/postorius/domains/) I added 2 Domains as Mail Hosts test1.xyz.de and test2.xyz.de with the corresponding Web hosts as stated above
> -> I added 1 list (/mailman3/postorius/lists/) for each Mail Domain as follows: test1(a)test1.xyz.de and test2(a)test2.xyz.de
> -> then created a vhost in apache2 with SSL-cert and added the Domains in ALLOWED_HOSTS: test1.xyz.de and test2.xyz.de
> -> When I go to the 2 Testdomains (corresponding web hosts), I see on each both lists for the different Mail domains
>
> What do I miss? Or where to investigate?
>
> Thank you in advance, best regards.
>
> By the way: what'S the difference in the 2 docs? https://docs.mailman3.org/en/latest/index.html and https://mailman.readthedocs.io/en/latest/README.html
Mailman Suite consists of several individual projects including Mailman Core, Postorius (Web UI) and
Hyperkitty (Archiver). The first URL is the landing page for the entire suite and should direct you to
individual projects. The second one is the individual Mailman Core project. Historically, Core was the
only project and hence claims the name “mailman” in most places.
>
> Am 18.03.21 um 21:52 schrieb Mark Sapiro:
>> On 3/18/21 9:20 AM, jens.guenther(a)posteo.de wrote:
>>> Is it possible, to only show publicly (if advertised) these lists on a certain url, that are corresponding to the web host the url I accessed mailman through?
>> Set FILTER_VHOST = True in your settings_local.py or where ever you put
>> your site Django settings.
> _______________________________________________
> Mailman-users mailing list -- mailman-users(a)mailman3.org
> To unsubscribe send an email to mailman-users-leave(a)mailman3.org
> https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/
--
thanks,
Abhilash Raj (maxking)
4 years, 3 months

[MM3-users] Re: Strange messages after upgrading Mailman3
by Allan Hansen
I asked the poster of one message what he had done.
Apparently, he had put the list address (just one list, according to him) in the Bcc: field.
The message was then held for moderator approval and, when approved, sent out without a body.
Another message was stopped because it did not have a subject field.
Again, it was approved and then sent out without a body.
From what I can see (the hold messages are sent to me as well), the messages were stripped after approval, as the approval messages have the message bodies.
I will try to ask my moderators not to approve messages that are held by the server and instead reply to the senders and discard the messages.
Yours,
Allan
P.S.: I had hoped that the upgrade would now allow the moderators to see the list of members, as that is enabled for each of my lists. It's now our top issue, with the change-of-address issue made easier. If moderators should not see the members list then maybe a third option on the menu should be 'Only list owners.' But it would be good for the moderators to see the list, as well as being able to subscribe and unsubscribe members.
On 12/5/22, 9:39 , "Mark Sapiro" <mark(a)msapiro.net> wrote:
On 12/5/22 08:56, Allan Hansen wrote:
> Thank you, Mark, as always.
>
> We upgraded to the latest versions:
>
> Mailman Core Version GNU Mailman 3.3.7 (Tom Sawyer)
> Mailman Core API Version 3.1
> Mailman Core Python Version 3.9.2 (default, Feb 28, 2021, 17:03:44) [GCC 10.2.1 20210110]
>
> Also, I don't have any umbrella lists.
I need more information about this. As far as I know, this can only
happen with messages that are cross posted to multiple lists and held
for moderator approval on more than one list. This should have been
fixed in Mailman 3.3.6 by
<https://gitlab.com/mailman/mailman/-/merge_requests/932>.
This should never happen with a post that is delivered to members
without being held.
Also, I think when this happens to a delivered post, the post in the
archive will also have the content lost message.
I would like to get as much information as possible about the
circumstances when this happens. In particular, was the post held for
moderation, was it posted to multiple lists, for how many lists was the
content lost. Also, it may help to see the full raw message with the
content lost notice. (If there are privacy concerns you can send these
to me off list)
--
Mark Sapiro <mark(a)msapiro.net> The highway is for gamblers,
San Francisco Bay Area, California better use your sense - B. Dylan
_______________________________________________
Mailman-users mailing list -- mailman-users(a)mailman3.org
To unsubscribe send an email to mailman-users-leave(a)mailman3.org
https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/
Archived at: mailman-users(a)mailman3.org <https://lists.mailman3.org/archives/list/<a href=>/message/33OOQ4DNXTJUNT65CD2KHMOSCAIMRSLL/">https://lists.mailman3.org/archives/list/mailman-users@mailman3.org/message…
This message sent to hansen(a)rc.org
___________________________________________
Mailman's content filtering has removed the
following MIME parts from this message.
Content-Type: image/jpeg
Name: members.jpg
2 years, 6 months

[MM3-users] Re: signup / registration error - permissions and cert chains
by Victoriano Giralt
El viernes, 31 de diciembre de 2021 1:48:38 (CET) David Newman escribió:
> I'd like for regular (non-admin) list subscribers to be able to manage
> their subscription preferences and view list archives.
That's a good way to go :-)
My response is more of a (very) old sysadmin and Django user (since 2008)
hunch that a proper one based on code and documentation review, but I've been
trying to contribute several times and always (super) Mark Sapiro beats me :-)
> If I'm reading the error correctly, this is related to an inability to
> verify the cert chain. The /etc/mailman3/settings.py file points to the
> same cert and key files used by Nginx, Postfix, and Dovecot.
You are right in your diagnose but not in your interpretation (see my comment
below inside the traceback). It is certificate related, but not for server
TLS, but for CLIENT authentication.
> EMAIL_BACKEND = 'django.core.mail.backends.smtp.EmailBackend'
> EMAIL_HOST = 'localhost'
> EMAIL_PORT = 25
> EMAIL_HOST_USER = 'dnewman(a)networktest.com'
> EMAIL_HOST_PASSWORD = 'wouldnt-you-like-to-know'
> EMAIL_USE_TLS = 'True'
> EMAIL_SSL_CERTFILE = '/etc/ssl/certs/myhost.crt'
> EMAIL_SSL_KEYFILE = '/etc/ssl/private/myhost.key'
All these settings above are used for SENDING messages and, if I'm not
mistaken, the SSL key and cert are used for authenticating the user sending
the email. Actually, using TLS and SMTP Auth for localhost is a bit too much.
I've been configuring SMTP servers since 1990 and my mail servers just accept
mail form localhost, if they are broken into, the user and password have
already been exposed :-)
> But this might only be for email, not Postorius/Django.
You are right (if I also am)
> What additional configuration is needed to allow regular users to create
> and manage their own accounts?
I'd say that is more what is not needed (the SMTP TLS authentication)
I'll remove the "noise". These are the tell tale lines:
> "/opt/mailman/venv/lib/python3.9/site-packages/django/core/mail/backends/smt
> p.py", line 67, in open
> self.connection.starttls(keyfile=self.ssl_keyfile,
> certfile=self.ssl_certfile)
The SMTP Django backend is trying to connect to the mail server to send the
Mailman account confirmation message and failing, probably because the user
Django runs as cannot open the private key (which is a very sensible thing if
that private key is the one used for the web facing TLS certificate, I can
tell you how bad in private or search for my name, wasd, apache and VMS ;-))
That certificate is not needed for sending email from Django, and, as I said,
not even SMTP Auth for sending via localhost. Actually, doing SMTP Auth on
port 25 is not even recommended practice.
Happy, healthy, safe and well ventilated New Year to all.
--
Victoriano Giralt Innovation Director
Digital Transformation Vicerectorate University of Malaga
+34952131415 SPAIN
==================================================================
Note: signature.asc is the electronic signature of present message
A: Yes.
> Q: Are you sure ?
>> A: Because it reverses the logical flow of conversation.
>>> Q: Why is top posting annoying in email ?
3 years, 6 months

[MM3-users] Re: search this list searches more then just this list
by Marco van Tol
Op 25 jan 2024, om 14:16 heeft Marco van Tol <mvantol(a)ripe.net> het volgende geschreven:
> Op 24 jan 2024, om 13:46 heeft Marco van Tol <mvantol(a)ripe.net> het volgende geschreven:
>> Op 24 jan 2024, om 12:24 heeft Marco van Tol <mvantol(a)ripe.net> het volgende geschreven:
>>> Op 23 jan 2024, om 19:09 heeft Mark Sapiro <mark(a)msapiro.net <mailto:mark@msapiro.net>> het volgende geschreven:
>>>>
>>>> On 1/23/24 05:49, Marco van Tol wrote:
>>>>> Small unfortunate twist, this leads to:
>>>>> ---
>>>>> [ERROR/MainProcess] Failed indexing 204001 - 205000 (retry 5/5): Term too long (> 245): ...
>>>>> ---
>>>>> I have seen comments on that from back in 2020, but what’s the latest advise on how to deal with this?
>>>>
>>>> This issue is discussed at <https://github.com/notanumber/xapian-haystack/pull/181>.
>>>> There are two patches for this issue. They are somewhat different approaches, but either one is OK. One patch is the one in the above PR <https://github.com/notanumber/xapian-haystack/pull/181/files>. The other is at <https://github.com/alexsilva/xapian-haystack/commit/a53523d2d0d13929a0729d4…>.
>>>>
>>>> I use the one from the PR, but it requires a substitution `s/force_text/str/`.
>>>
>>> Hi, thanks! Just to double check, do you mean `str` or `force_str` in the substitution?
>>>
>>> I found a comment on this topic regarding django-4 where they advice to use force_str.
>>> https://stackoverflow.com/questions/70382084/import-error-force-text-from-d…
>>
>> Hm, never mind, sorry. I now see the current file already has str() rather than force_text() in it.
>
> Okay, so, I got a bit further, but something still gets stuck.
>
> Here’s what I did.
> Keep in mind I’m using containers that are built from some CI/CD pipeline, so I updated the pipeline to apply the patch attached to this email to `/usr/lib/python3.11/site-packages/xapian_backend.py`.
>
> Before I had 2 list servers with the “Term too long” issue, 1 got resolved by this, and the other did not.
> I opened a shell in the newly deployed container to confirm the patch was applied in it.
>
> The other attachment to this email is a copy/paste from the full error from `./manage.py rebuild_index`.
>
> Is there something else special in the email that makes it choke that evades the xapian patch?
>
> Thank you very much in advance!
I tried to change to ‘hash’, but the code in that bit of the function has not been tested enough.
For example `hole = sha224(hole.encode('utf8')).hexdigest()` comes back with that the bytes object hole does not have an encode() method.
When I change it to `hole = sha224(hole).hexdigest()`, the following error is:
text = text[:match.start()] + hole + text[match.end():]
TypeError: can't concat str to bytes
The ‘hash’ part of that function needs some debugging.
Marco
1 year, 5 months

[MM3-users] Re: logrotate
by Odhiambo Washington
On Wed, May 3, 2023 at 2:38 AM Mark Sapiro <mark(a)msapiro.net> wrote:
> Please don't hijack threads. Post a new topic as an original post, not
> as a reply to an old thread.
>
> On 5/2/23 15:45, Christian via Mailman-users wrote:
> > I noticed that my mailman logfiles are not being rotated. I followed the
> > instructions in
> >
> https://mail.python.org/archives/list/mailman-developers@python.org/message/
> > FM3TSMQ63JR2KROJGOSPENODOOQVRYCL/
>
>
> Those instructions are for Mailman 2.1.
>
>
> > Now when I try and run logrotate I get the following error
> >
> > root@zarathustra:/opt/mailman/mm/logs# logrotate /etc/logrotate.conf
> > error: stat of /opt/mailman/mm/logs/bounce.log failed: No such file or
> > directory
> > error: stat of /opt/mailman/mm/error.log failed: No such file or
> directory
> > error: stat of /opt/mailman/mm/mailman.log failed: No such file or
> > directory
> > error: stat of /opt/mailman/mm/mailmansuite.log failed: No such file or
> > directory
> > error: stat of /opt/mailman/mm/smtp.log failed: No such file or
> directory
> > root@zarathustra:
> >
> > What am I doing wrong please?
>
> Here's a logrotate script I use:
> ```
> /opt/mailman/mm/var/logs/*.log {
> missingok
> sharedscripts
> su mailman mailman
> postrotate
> sudo -u mailman /opt/mailman/mm/bin/mailman reopen &>/dev/null
> || true
> if [ -r /opt/mailman/mm/var/gunicorn.pid ]; then
> PID=`cat /opt/mailman/mm/var/gunicorn.pid`
> kill -s USR1 $PID
> fi
> endscript
> }
> ```
> A couple of caveats. The first line of the postrotate script may be
> wrapped. `sudo ... true` is all one line.
>
> That line could also be
> ```
> /opt/mailman/mm/bin/mailman --run-as-root reopen &>/dev/null || true
> ```
> I.e., it either has to run as the mailman user or specify the
> --run-as-root option.
>
> Also, if logs aren't in /opt/mailman/mm/var/logs/ or gunicorn.pid isn't
> in /opt/mailman/mm/var/ those paths need adjusting.
>
> Finally, there may be an issue with `mailman reopen` in the postrotate
> scrupt. See https://gitlab.com/mailman/mailman/-/issues/1078
>
>
In my case, I took a different approach with Django's logging configuration:
[snip]
'handlers': {
'file': {
'level': 'INFO',
'class': 'logging.handlers.TimedRotatingFileHandler',
'filename': '/opt/mailman/mm/var/logs/mailmanweb.log',
'when': 'D', # specifies the interval
'interval': 1, # defaults to 1, only necessary for other values
'backupCount': 5, # how many backup file to keep, 5 days
'formatter': 'simpleRe',
},
},
[snip]
I have not been rotating the other log files as my list is not a
high-volume one so logs aren't growing much.
Plus I only rely on the logs for diagnostics, not for records ;(
--
Best regards,
Odhiambo WASHINGTON,
Nairobi,KE
+254 7 3200 0004/+254 7 2274 3223
"Oh, the cruft.", egrep -v '^$|^.*#' ¯\_(ツ)_/¯ :-)
[How to ask smart questions:
http://www.catb.org/~esr/faqs/smart-questions.html]
2 years, 1 month

[MM3-users] Re: About to Install MM3 -- Seeking clarification
by Eggert Ehmke
I have this in my mailman3.service file:
[Service]
Type=forking
PIDFile=/opt/mailman/mm/var/master.pid
Environment="MAILMAN_CONFIG_FILE=/etc/mailman3/mailman.cfg"
User=mailman
Group=mailman
ExecStart=/opt/mailman/venv/bin/mailman start
ExecReload=/opt/mailman/venv/bin/mailman restart
ExecStop=/opt/mailman/venv/bin/mailman stop
That works fine.
Am Dienstag, 25. Oktober 2022, 07:06:57 CEST schrieb Onyeibo Oku:
> On Sun, 23 Oct 2022 08:00:19 -0700
>
> Mark Sapiro <mark(a)msapiro.net> wrote:
> > On 10/22/22 21:29, Onyeibo Oku wrote:
> > > Now Mailman starts, and stops as desired when running as mailman
> > > user (both in virtual and non-virtual environments). However,
> > > running the service via systemd still fails. I now get a different
> > > traceback:
> > >
> > > Oct 23 03:43:00 mail.server.tld mailman[19410]: Traceback (most
> >
> > > recent call last):
> > ...
> >
> > > Oct 23 03:43:00 mail.server.tld mailman[19410]: with
> > > open(self._claimfile, 'w') as fp: Oct 23 03:43:00 mail.server.tld
> > > mailman[19410]: PermissionError: [Errno 13] Permission denied:
> > > '/opt/mailman/mm/var/locks/mailman-cfg.lck|server.tld|19410|619270043958
> > > 240354' Oct 23 03:43:00 mail.server.tld systemd[1]: mailman3.service:
> > > Control process exited, code=exited, status=1/FAILURE
> >
> > What are ownership and permissions on /opt/mailman/mm/var/locks/
> >
> > Assuming they are
> >
> > drwxr-xr-x mailman mailman
> >
> > it must be the case that systemd is not running the
> > `/opt/mailman/venv/bin/mailman start` command as the `mailman` user.
> > I suspect this is a Fedora issue. I note that
> > https://docs.fedoraproject.org/en-US/quick-docs/understanding-and-administ
> > ering-systemd/#_service_parameters does not mention User or Group. You
> > might try replacing
> > ```
> > ExecStart=/opt/mailman/venv/bin/mailman start
> > ExecReload=/opt/mailman/venv/bin/mailman restart
> > ExecStop=/opt/mailman/venv/bin/mailman stop
> >
> > with
> >
> > ExecStart=sudo -u mailman /opt/mailman/venv/bin/mailman start
> > ExecReload=sudo -u mailman /opt/mailman/venv/bin/mailman restart
> > ExecStop=sudo -u mailman /opt/mailman/venv/bin/mailman stop
> > ```
>
> This does not work. Systemd says it cannot find sudo (file). After
> updating in the commands "sudo" to "/bin/sudo" afterwards Systemd throws
> a different error message: PermissionError on /bin/sudo
>
> This is tiring. At this moment I am left with the possibility that
> SELinux may be in the way. I cannot think of a way to prove this
> hypothesis. This is speculation. Perhaps I should try another
> installation method other than Virtual. I found Mailman3 in Fedora
> repository. Yes, it is packaged. May be I should try that or perhaps I
> should try the git version. I'd be happy to have a functioning Mailman
> before Friday.
>
>
> Regards
> Onyeibo
> _______________________________________________
> Mailman-users mailing list -- mailman-users(a)mailman3.org
> To unsubscribe send an email to mailman-users-leave(a)mailman3.org
> https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/
2 years, 8 months

[MM3-users] Re: problems installing mailman3 under gentoo and upgrading mailman2 to mailman3
by John Covici
I don't think this reply got to the mailing list, so I am sending it
again, sorry if its a duplicate.
On Sat, 13 Mar 2021 00:33:58 -0500,
Mark Sapiro wrote:
>
> On 3/12/21 7:36 PM, John Covici wrote:
> > Hi. I am having a great deal of difficulty installing mailman3 using
> > gentoo and sendmail. Also, I want to upgrade my old mailman2 data to
> > mailman3.
> >
> > What I have done so far is to install the mailman3 packages from my
> > repository and got this:
> > django-mailman3 version 1.3.4, mailmanclient version 3.3.1, mailman
> > version 3.3.2 (apparently the core), postorius version 1.3.3 and
> > hyperkitty version 1.3.3. I also have mariadb and postgresql already installed.
>
>
> Are these gentoo packages? If so, I have no idea how they are
> configured.
Anyway I can tell, there was no configuration (we call them use flags)
they just seemed to install the files in what seems to be the correct
places.
>
>
> > Now trying to read your documentation, it seems it wants me to
> > reinstall some packages using pip in the home directory of the mailman
> > user in a python virtual environment, that was the first thing. But I
> > would like to avoid multiple package managers wherever possible --
> > gentoo is already a lot of maintainance without dealing with pip's
> > maintainance. The binaries also seem to be different from my gentoo packages.
>
>
> Our documantation generally covers installing from source. If you are
> installing gentoo packages, you should be looking at gentoo docs and
> going to gentoo for help.
>
> We recommend installing Mailman and the web components in a virtualenv,
> but it is not a requirement. We also suggest that postgresql is a better
> choice than MariaDB.
>
I sort of am installing from source, gentoo installs from source. No
one on the gentoo users mailing list seems to be able to help me,
except to tell me to use a different mailing list mechanism called
mlmmj.
>
> > So, how do I proceed with getting mailman3 up and working, configuring
> > the database, configs, etc and I guess after doing that upgrading
> > mailman2 and getting sendmail to interface properly with mailman3?
>
> Importing lists from Mailman 2 is done with the `mailman import21`
> command. See
> <https://docs.mailman3.org/projects/mailman/en/latest/src/mailman/commands/d…>.
> Importing archives is done with the Django management
> `hyperkitty_import` command. See
> <https://docs.mailman3.org/projects/hyperkitty/en/latest/install.html#import…>
>
> For sendmail, see
> <https://docs.mailman3.org/projects/mailman/en/latest/src/mailman/docs/mta.h…>
Thanks.
--
Your life is like a penny. You're going to lose it. The question is:
How do
you spend it?
John Covici wb2una
covici(a)ccs.covici.com
--
Your life is like a penny. You're going to lose it. The question is:
How do
you spend it?
John Covici wb2una
covici(a)ccs.covici.com
4 years, 3 months

[MM3-users] Re: Confusing mailman user model
by Gilles Filippini
Gilles Filippini a écrit le 19/07/2020 à 19:10 :
> Gilles Filippini a écrit le 19/07/2020 à 18:00 :
>> Mark Sapiro a écrit le 19/07/2020 à 17:30 :
>>> On 7/19/20 8:10 AM, Gilles Filippini wrote:
>>>> Hi,
>>>>
>>>> I'm trying to understand the Mailman user model, and I'm confused about
>>>> the respective roles of tables 'auth_user' and 'user'.
>>>
>>>
>>> auth_user is a Django auth table. These are the users listed in the
>>> Django admin web UI.
>>>
>>> user is Mailman core's users.
>>>
>>>
>>>> Both have an 'id' column referred to as 'user_id' when used as a foreign
>>>> key. But there seems to be no relation at all between them as they use
>>>> different ids for the same user.
>>>
>>>
>>> Right, they are unrelated.
>>>
>>>
>>>> Our mailman server was migrated from mailman2 to mailman3 about 1.5 year
>>>> ago, and there is an inconsistency I'd like to fix:
>>>> 2 of our users have a registered Mailman account with their respective
>>>> email addresses in table 'auth_user', but these very same addresses in
>>>> the 'address' table are linked to another old admin account in the
>>>> 'user' table.
>>>
>>> Their Mailman account is the 'old' one. the auth_user account is a
>>> Django account
>>>>
>>>> Then if add one of these addresses as a domain owner, it it the old
>>>> admin address which is selected instead. How could I fix that?
>>>
>>>
>>> That's because domain owner in a Mailman thing and involvs the Mailman
>>> user. You could delete the Django users via the Django admin UI and then
>>> re-register them via Postorius. That *might* work.
>>
>> When login into postorius, it is the Django account that is used, right?
>> Then how is the mailman account retrieved from there? It seems UUIDs are
>> used in the process, but I fail understanding how, so far. Wouldn't it
>> be safe to retrieve the new Mailman account associated to these Django
>> users, and link there emails from 'address' table' to them?
>
> Reading the mailman-web source code I understand now that the mailman
> account is retrieved from the Django account email address. Then both
> users are tied to the same old mailman admin account, and deleting then
> registering them again won't change anything on this aspect.
>
> Would this work?
> 1- For both addresses, update their record in table 'address' to set
> 'user_id' to null
> 2- On their next login to Mailman-web, a new mailman account would be
> created and associated with their own email address.
Done that, and it worked.
Thanks,
_g.
4 years, 11 months

[MM3-users] Re: [Spam] Installation Help on Ubuntu 18
by Odhiambo Washington
On Sun, 26 Jul 2020 at 18:22, Mark Sapiro <mark(a)msapiro.net> wrote:
> On 7/26/20 12:37 AM, Stephen J. Turnbull wrote:
> >
> > That's not our guide, we don't support it, and at least I don't
> > recognize the author offhand, can't speak for the rest of the team.
>
>
> The author has been involved in a few threads on this list.
>
>
> > Now that our NO WARRANTY notice is out of the way, I will say that
> > guide is written in very good style, with great attention to detail
> > and appropriate warnings about delicate parts of the procedure. If
> > you end up succeeding with it, I'll add a link to it to our docs.
>
>
> It is currently linked from the first paragraph at
> <https://wiki.list.org/DOC/Mailman%203%20installation%20experience>.
>
I followed the steps outlined in the subject document and got mailman3
running.
However, what is missing in that document is the process of setting up a
webserver for accessing the MM3 UI.
I have spent two days trying to figure out that aspect and discovered a few
things (I could be wrong in what I think):
1. For one to use the uwsgi.ini that is dropped in /etc/mailman3/ by the
installation process, the uwsgi daemon must be installed:
*apt install uwsgi-core uwsgi*
2. The uwsgi.ini must be linked in the directory where the uwsgi daemon
looks for config files:
*cp /etc/mailman3/uwsgi.ini /etc/uwsgi/apps-available/uwsgi.ini*
*ln -s /etc/uwsgi/apps-available/uwsgi.ini
/etc/uwsgi/apps-enabled/uwsgi.ini*
3. The uwsgi daemon needs to be started
*systemctl start uwsgi*
root@lists:/etc/mailman3# ps ax | grep wsgi
5838 ? S 0:00 /usr/bin/uwsgi --ini
/usr/share/uwsgi/conf/default.ini --ini /etc/uwsgi/apps-enabled/uwsgi.ini
--daemonize /var/log/uwsgi/app/uwsgi.log
5841 ? Sl 0:00 /usr/bin/uwsgi --ini
/usr/share/uwsgi/conf/default.ini --ini /etc/uwsgi/apps-enabled/uwsgi.ini
--daemonize /var/log/uwsgi/app/uwsgi.log
5842 ? Sl 0:00 /usr/bin/uwsgi --ini
/usr/share/uwsgi/conf/default.ini --ini /etc/uwsgi/apps-enabled/uwsgi.ini
--daemonize /var/log/uwsgi/app/uwsgi.log
Now that uwsgi daemon is running, the last step would be to configure the
webserver to serve the MM3 pages.
The apache config snippet dropped by the mailman3 install process in
/etc/mailman3/apache.conf contains:
<BEGIN>
Alias /mailman3/favicon.ico
/var/lib/mailman3/web/static/postorius/img/favicon.ico
Alias /mailman3/static /var/lib/mailman3/web/static
<Directory "/var/lib/mailman3/web/static">
Require all granted
</Directory>
<IfModule mod_proxy_uwsgi.c>
ProxyPass /mailman3/favicon.ico !
ProxyPass /mailman3/static !
ProxyPass /mailman3
unix:/run/mailman3-web/uwsgi.sock|uwsgi://localhost/
</IfModule>
<END>
I added those to a virtualhost where I am running mailman2.x, but I
couldn't access any of the defined aliases:
https://lists.my.site/mailman3/static/ - gives "You don't have permission
to access this resource."
Apache says
AH01276: Cannot serve directory /var/lib/mailman3/web/static/: No matching
DirectoryIndex (index.html,index.cgi,index.pl,index.php,index.xhtml,index.htm)
found, and server-generated directory index forbidden by Options directive
I am stuck at that point ...
--
Best regards,
Odhiambo WASHINGTON,
Nairobi,KE
+254 7 3200 0004/+254 7 2274 3223
"Oh, the cruft.", grep ^[^#] :-)
4 years, 11 months

[MM3-users] Re: Multi-domain oddities in Hyperkitty and Postorius
by Jeremy Stanley
On 2023-01-30 12:08:10 -0800 (-0800), Mark Sapiro wrote:
[...]
> Domains can be created via Postorius or via the Mailman Core REST API that
> postorius uses or implicitly by the `mailman create` command when creating a
> list in a new domain. However, none of this can create a new site. You can
> do this through the Django admin site at sites/site/add/.
>
> See https://docs.djangoproject.com/en/4.1/ref/contrib/sites/ for methods you
> can use to do this programmatically.
Thanks, I'm still doing my best to wrap my brain around how Django
uses database migrations to create sites (seems like a very strange
use of a migration, I'm only accustomed to seeing them applied for
database schema updates). Once I work out how to script site
creation, I'm still not completely finding the explanations I need
for how to map them to domains in Mailman though.
The Mailman documentation about domains says "Domains are how
Mailman interacts with email host names and web host names" but
doesn't actually go on to say (that I can find anywhere) how it
actually associates them. I can see in the API docs that a POST to
the domains endpoint will create a new domain with a specific
mail_host FQDN, but there's some association somewhere of that to a
web host (Django site), right? How is that set or manipulated
through the API? Or is that something which has to be set directly
in Django's data structures instead?
To recap, on creation of a mailing list server I want to populate it
automatically with multiple lists on different domains and have
dynamic SITE_ID=0 domain guessing performed so that the correct site
name and list filtering is performed depending on which domain name
is used in a URL the client requests. I believe I need to have the
automation perform the following steps:
1. Instantiate the Mailman installation and run initial migrations
with SITE_ID=1 in order to avoid the problem mentioned in the docs
about not using SITE_ID=0 until the tables have been populated, then
switch the settings.py to use SITE_ID=0 once done.
2. Create the individual sites I need in Django (Mailman web hosts)
by creating and applying database migrations.
3. Create the individual domains I need in Mailman (Mailman mail
hosts) through its REST API.
4. "Somehow" tell Mailman (or Django?) which mail hosts correspond
to what web hosts.
As I said, I'm still trying to understand how to make step 2 happen
(Django has a steep learning curve for me), but beyond that I'm
unsure how to do step 4 at all. I can do all of this through the
WebUI of course, and have confirmed that it works as expected when I
do, I'm just trying to work out the automation so that our other
sysadmins don't have to perform these steps by hand the next time we
need to rebuild the server.
Thanks again for all the help so far, and for any additional insight
anyone may have into how I can correct my mental model of all this.
--
Jeremy Stanley
2 years, 4 months

[MM3-users] Re: List Migration from MM2.1 -> MM3
by Odhiambo Washington
On Mon, Aug 15, 2022 at 1:31 AM Mark Sapiro <mark(a)msapiro.net> wrote:
> On 8/14/22 11:04, Odhiambo Washington wrote:
> > So I thought I have everything running. Fresh install of MM3 on
> > Ubuntu-22.04.
> >
> > I have created a list in postorius - it has the same name as my old list
> in
> > MM2.
> >
> > [image: MM3.png]
>
> Your image didn't make it through content filtering.
>
The image only showed a listing of the MLs that I created via postorius.
>
> What is the fully qualified name of the list
>
skunkworks(a)lists.my.co.ke
> > mailman@lists:~$ /opt/mailman/mm/venv/bin/mailman import21
> skunkworks(a)lists.my.co.ke /var/list/lists/skunkworks/config.pck
> > Usage: mailman import21 [OPTIONS] LISTSPEC PICKLE_FILE
> > Try 'mailman import21 -h' for help.
> >
> > Error: No such list: skunkworks(a)lists.my.co.ke
>
> Apparently the list you created is not named skunkworks(a)lists.my.co.ke
Apparently so, because:
mailman@lists:~$ /opt/mailman/mm/venv/bin/mailman lists
No matching mailing lists found
mailman@lists:~$
Which is surprising, given this: https://imgur.com/a/LPrh42K
> > What am I missing?
>
> The Mailman 3 list skunkworks(a)lists.my.co.ke including that exact domain
> must exist in order to import to it. Try
>
> /opt/mailman/mm/venv/bin/mailman create skunkworks(a)lists.my.co.ke
root@lists:/home/wash# su - mailman
mailman@lists:~$ /opt/mailman/mm/venv/bin/mailman create
skunkworks(a)lists.my.co.ke
sh: 1: /usr/sbin/postmap: not found
sh: 1: /usr/sbin/postmap: not found
Traceback (most recent call last):
File "/opt/mailman/mm/venv/bin/mailman", line 8, in <module>
sys.exit(main())
File "/opt/mailman/mm/venv/lib/python3.10/site-packages/click/core.py",
line 1130, in __call__
return self.main(*args, **kwargs)
File "/opt/mailman/mm/venv/lib/python3.10/site-packages/click/core.py",
line 1055, in main
rv = self.invoke(ctx)
File
"/opt/mailman/mm/venv/lib/python3.10/site-packages/mailman/bin/mailman.py",
line 69, in invoke
return super().invoke(ctx)
File "/opt/mailman/mm/venv/lib/python3.10/site-packages/click/core.py",
line 1657, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File "/opt/mailman/mm/venv/lib/python3.10/site-packages/click/core.py",
line 1404, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "/opt/mailman/mm/venv/lib/python3.10/site-packages/click/core.py",
line 760, in invoke
return __callback(*args, **kwargs)
File
"/opt/mailman/mm/venv/lib/python3.10/site-packages/click/decorators.py",
line 26, in new_func
return f(get_current_context(), *args, **kwargs)
File
"/opt/mailman/mm/venv/lib/python3.10/site-packages/mailman/commands/cli_lists.py",
line 184, in create
mlist = create_list(fqdn_listname, owners)
File
"/opt/mailman/mm/venv/lib/python3.10/site-packages/mailman/app/lifecycle.py",
line 100, in create_list
call_name(config.mta.incoming).create(mlist)
File
"/opt/mailman/mm/venv/lib/python3.10/site-packages/mailman/mta/postfix.py",
line 93, in create
self.regenerate()
File
"/opt/mailman/mm/venv/lib/python3.10/site-packages/mailman/mta/postfix.py",
line 133, in regenerate
raise RuntimeError(NL.join(errors))
RuntimeError: command failure: /usr/sbin/postmap
/opt/mailman/var/data/postfix_lmtp, 127, Key has expired
command failure: /usr/sbin/postmap /opt/mailman/var/data/postfix_domains,
127, Key has expired
Now that wants Postfix, while I don't use Postfix, but Exim as the MTA.
--
Best regards,
Odhiambo WASHINGTON,
Nairobi,KE
+254 7 3200 0004/+254 7 2274 3223
"Oh, the cruft.", egrep -v '^$|^.*#' ¯\_(ツ)_/¯ :-)
2 years, 10 months

[MM3-users] Re: What to backup?
by Alain Kohli
Thanks for the great explanation, that helped a lot! I'll try to work on
that issue if I find some time. In the meantime it would be neat to try
to clean up the old messages right before the backup. How can you
distinguish messages that have been moderated already? I couldn't really
find that in the database or the models.
On 5/26/19 8:18 PM, Mark Sapiro wrote:
> On 5/26/19 7:00 AM, Alain Kohli wrote:
>> I have noticed that especially the var/messages directory has a rather
>> considerable size compared to the rest. What exactly is this for and
>> what would be the consequences if that was lost?
>
> When a message is held for moderator approval, a pickle of the message
> is stored in the var/messages directory and an entry pointing to it is
> made in the message table in the database. An entry is also made in the
> list's pending requests. These are required so the held message can be
> handled.
>
> There is an issue in that when these messages are handled these aren't
> removed. See <https://gitlab.com/mailman/mailman/issues/257>.
>
> Thus, most of what's in the var/messages directory is old, but there are
> also currently held messages there that would be lost.
>
> You could periodically remove older messages, but this would leave
> entries pointing to them in the message table in the database which
> could cause errors but probably not.
>
> The real solution is a fix for
> <https://gitlab.com/mailman/mailman/issues/257>.
>
>> And more generally, would not backing up var/ at all only result in the
>> loss of some short term data (e.g. messages that are held or currently
>> processed) or would long term data also be lost? Or in other words, what
>> exactly would be non-recoverable if that isn't backed up?
>
> That depends in part on what your backend database is. If it's SQLite,
> the database is probably in the var/data directory. If not, you need to
> be backing up the MySQL or postgreSQL mailman database.
>
> var/archives contains archived messages for the 'prototype' archiver and
> messages that are queued for hyperkitty.
>
> var/cache contains a cache of recently used templates.
>
> var/data may contain a SQLite database and may contain Postfix mappings.
> The Postfix mappings can be regenerated by the `mailman aliases` command.
>
> var/etc may contain your mailman.cfg if you don't point to a different one.
>
> var/lists contains accumulated messages for the next digest for your lists
>
> var/locks contains locks and should probably not be restored from a backup
>
> var/logs contains Mailman's logs.
>
> var/messages is discussed above.
>
> var/queue contains Mailman's current queues. Except for 'shunt' this is
> all things currently in process.
>
> var/templates may contain custom templates.
>
> Also, I didn't mention it before, but your Django settings.py and
> settings_local.py should also be backed up.
>
6 years, 1 month

[MM3-users] Re: Post-installation documentation?
by David Newman
On 11/25/21 1:16 PM, Mark Sapiro wrote:
> On 11/25/21 10:56 AM, David Newman wrote:
>>
>> Thanks for this. After setting these variables and restarting mailman3
>> and mailmanweb, the mailman user still cannot find a hyperkitty_import
>> command (neither can root, btw). Again, I installed MM3 and
>> Django/Postorius/Hyperkitty using the venv and web docs previously
>> referenced.
>
>
> Don't run mailman or django admin commands as root. This causes issues
> when files are created by root and can't be read by mailman.
Understood, thanks. I'd only tried root to determine if there was a
permissions issue, where hyperkitty_import really did exist but wasn't
available to the mailman user.
>
> What django admin command are you running?
As the mailman user, with venv activated:
(venv) mailman@lists:~$ hyperkitty_import -l testlist(a)lists.domain.com
/var/lib/mailman/archives/private/testlist.mbox/testlist.mbox
'testlist' and 'lists.domain.com' are redactions; they are correct in
the given command, but the command fails because the system can't find
hyperkitty_import.
(BTW
Also, because I'm looking to migrate from Mailman 2.1 installed from
Debian packages, all the 2.1 stuff is owned by the 'list' user. I'd
changed ownership of the above private archive to mailman:mailman for
the command not to complain about permissions.
> If you don't set
> DJANGO_SETTINGS_MODULE in the environment and you have activated your
> virtualenv and run `mailman-web` as the django admin command it will set
> /etc/mailman3/settings.py as the settings.
I'd run these two environment commands as the mailman user with
virtualenv activated:
export DJANGO_SETTINGS_MODULE=settings
export PYTHONPATH=/etc/mailman3/settings.py
Am I being overly literal here with 'settings' in that first command?
Asking because 'mailman-web check' runs clean before running these
commands and returns this error afterward:
ModuleNotFoundError: No module named 'settings'
Either way, the hyperkitty_import command still isn't found.
>> On the plus side, all lists now appear in the admin web page. However,
>> lists created from the admin page do not appear in a site list page,
>> even though all lists are in the same site/domain.
>
>
> By default, only lists that you are owner, moderator or subscriber for
> are shown. What if you click Filter by Role and select All?
Same result. In this case, the ID of the admin and list owner are the same.
>
>
>> Finally, how to make these exports permanent? I did not see this
>> covered in the migration doc above. This is on a Debian system where
>> the mailman user's shell is bash. Is this simply a matter of adding
>> environment variables in the mailman user's .bashrc file?
>
> You can do that but as I note above, if you run `mailman-web` you
> shouldn't need to. You can add a `source /opt/mailman/venv/bin/activate`
> command as mentioned at
> https://docs.mailman3.org/en/latest/install/virtualenv.html#activate-virtua….
Yes, this is what I have in mailman's .bashrc file. I'd followed that
venv doc for initial installation, and it activates the virtualenv
whenever launching a shell for mailman.
dn
3 years, 7 months

[MM3-users] Re: External MTA incoming mail: configuration
by Roland Giesler
On 2024/08/02 19:02, Mark Sapiro wrote:
> On 8/2/24 09:43, Roland Giesler via Mailman-users wrote:
>
>> Ah, so I just have to figure out why the LMTP runner is not running.
>
> Stop Mailman core and then start it. You must stop and then start as
> opposed to restart.
>
> If lmtp runner is not running after that check
> /var/log/mailman3/mailman.log for possible reasons. You can also check
> that log for reasons why it isn't currently running.
>
> You can also check /var/log/syslog* for events like out_of_memory that
> might have killed it.
I do now have the lmtp runner on port 8024.
# netstat -tunap | grep 8024
tcp 0 0 192.168.161.103:8024 0.0.0.0:*
LISTEN 46730/python3
In mailman.cfg I set it to listen on the LAN address instead of
172.0.0.1, since I'm expecting mails from my external MTA server.
In the logs of the MTA I see this however: warning: do not list domain
fast.za.net in BOTH virtual_mailbox_domains and relay_domains
Mailman creates these entries, but postfix doesn't like it. I don't see
any mail delivered to the mailman yet. Is this the problem?
In the MTA postfix main.cf:
relay_domains = hash:/etc/mailman3/data/postfix_domains
cat /etc/mailman3/data/postfix_domains
# AUTOMATICALLY GENERATED BY MAILMAN ON 2024-08-05 07:20:17
#
# This file is generated by Mailman, and is kept in sync with the binary
hash
# file. YOU SHOULD NOT MANUALLY EDIT THIS FILE unless you know what you're
# doing, and can keep the two files properly in sync. If you screw it up,
# you're on your own.
fast.za.net fast.za.net
and also
local_recipient_maps=$virtual_mailbox_maps,
hash:/etc/mailman3/data/postfix_lmtp
cat /etc/mailman3/data/postfix_lmtp
# AUTOMATICALLY GENERATED BY MAILMAN ON 2024-08-05 07:20:17
#
# This file is generated by Mailman, and is kept in sync with the binary
hash
# file. YOU SHOULD NOT MANUALLY EDIT THIS FILE unless you know what you're
# doing, and can keep the two files properly in sync. If you screw it up,
# you're on your own.
# Aliases which are visible only in the @fast.za.net domain.
test(a)fast.za.net lmtp:[192.168.161.103]:8024
test-bounces(a)fast.za.net lmtp:[192.168.161.103]:8024
test-confirm(a)fast.za.net lmtp:[192.168.161.103]:8024
test-join(a)fast.za.net lmtp:[192.168.161.103]:8024
test-leave(a)fast.za.net lmtp:[192.168.161.103]:8024
test-owner(a)fast.za.net lmtp:[192.168.161.103]:8024
test-request(a)fast.za.net lmtp:[192.168.161.103]:8024
test-subscribe(a)fast.za.net lmtp:[192.168.161.103]:8024
test-unsubscribe(a)fast.za.net lmtp:[192.168.161.103]:8024
Then there's:
virtual_mailbox_domains=sqlite:/etc/postfix/virtual-mailbox-domains.cf
cat /etc/postfix/virtual-mailbox-domains.cf
dbpath=/home/user-data/mail/users.sqlite
query = SELECT 1 FROM users WHERE email LIKE '%%@%s' UNION SELECT 1 FROM
aliases WHERE source LIKE '%%@%s' UNION SELECT 1 FROM auto_aliases WHERE
source LIKE '%%@%s'
When I run that query in sqlite3, it returns no records, so I'm not sure
how this is supposed to work. %s to me means that first argument, so is
this used in python and then %s is the argument sent to this query?
The bottom line of this all is that a new signup message that I reply to
is being received by box2.gtahardware,co.za, but not by mailman3 and I
cannot find the point where it fails in the logs.
10 months, 3 weeks

[MM3-users] Re: National language messages in mm3 notifications
by Ivan Kuznetsov
Hello
All works fine if all the site, mailing list and user languages are
equal. But I found at least two corner cases if languages are not same:
1) Site language is Russian. User default language is US English. User
subscribes to mailing list with non-English preferred language (Russian)
User greeting message have correct body encoding but garbled Subject:
header:
=================
Return-Path: <test-bounces(a)solvo.ru>
[...]
MIME-Version: 1.0
Content-Type: text/plain; charset="us-ascii"
Content-Transfer-Encoding: 7bit
Subject: ????? ?????????? ? ?????? ???????? "Test"
From: test-request(a)solvo.ru
To: =?utf-8?b?0JjQstCw0L0g0JrRg9C30L3QtdGG0L7QsiAo0YLQtdGB0YIp?=
<ikuznetsov(a)solvo.ru>
X-No-Archive: yes
Message-ID:
<164370087756.3121264.15600221365450238466(a)mail-g3-vlan10.solvo.ru>
Date: Tue, 01 Feb 2022 10:34:37 +0300
Precedence: bulk
X-Mailman-Version: 3.3.5
List-Id: =?utf-8?b?0KLQtdGB0YLQvtCy0YvQuSDRgdC/0LjRgdC+0Lo=?=
<test.solvo.ru>
List-Help: <mailto:test-request@solvo.ru?subject=help>
List-Owner: <mailto:test-owner@solvo.ru>
List-Subscribe: <mailto:test-join@solvo.ru>
List-Unsubscribe: <mailto:test-leave@solvo.ru>
Welcome to the "Test" mailing list!
To post to this list, send your message to:
test(a)solvo.ru
[...]
=================
2) Site language is Russian. User default language is US English. User
subscribes to mailing list with preferred US English language.
Moderator notify message has Subject: garbled
=================
Return-Path: <test-bounces+kia=solvo.ru(a)solvo.ru>
[...]
MIME-Version: 1.0
Content-Type: text/plain; charset="us-ascii"
Content-Transfer-Encoding: 7bit
Subject: ????? ?????? ?? ???????? ?? ?????? ???????? Test ??
ikuznetsov(a)solvo.ru
From: test-owner(a)solvo.ru
To: =?utf-8?b?0JjQstCw0L0g0JrRg9C30L3QtdGG0L7Qsg==?= <kia(a)solvo.ru>
Message-ID:
<164370607233.3121263.10615836031266859672(a)mail-g3-vlan10.solvo.ru>
Date: Tue, 01 Feb 2022 12:01:12 +0300
Precedence: bulk
X-Mailman-Version: 3.3.5
List-Id: =?utf-8?b?0KLQtdGB0YLQvtCy0YvQuSDRgdC/0LjRgdC+0Lo=?=
<test.solvo.ru>
List-Help: <mailto:test-request@solvo.ru?subject=help>
List-Owner: <mailto:test-owner@solvo.ru>
List-Subscribe: <mailto:test-join@solvo.ru>
List-Unsubscribe: <mailto:test-leave@solvo.ru>
X-DrWeb-SpamScore: 315
X-DrWeb-SpamState: spam
X-DrWeb-SpamDetail:
gggruggvucftvghtrhhoucdtuddrgedvvddrgedvgdduvdeiucetufdoteggodetrfcurfhrohhfihhlvgemucfftfghgfeunecuuegrihhlohhuthemuceftddtnecuogetfedtuddqtdduucdludehmdenogfogedtledqfeefucdlfedttddmnecujfgurhepgggtgffuhffvkfffphejfedvtdfjsehtjeertddttddvnecuhfhrohhmpehtvghsthdqohifnhgvrhesshholhhvohdrrhhunecuggftrfgrthhtvghrnheptedvledvheefueekieektdeuueeiheekffehleeuffeiteeuteelheeggfeftdfg
X-DrWeb-SpamVersion: Vade Retro 01.422.42#126 AS+AV+AP Profile: DRWEB;
Bailout: 300
X-AntiVirus: Checked by Dr.Web [MailD: 11.1.12.2108031732, SE:
11.1.7.2106242330, Core engine: 7.00.52.08270, Virus records: 10792308,
Updated: 2022-Feb-01 07:11:29 UTC]
Message-ID-Hash: KFWOCUEE7SSJMLW222QGFECTNTBXYDEG
X-Message-ID-Hash: KFWOCUEE7SSJMLW222QGFECTNTBXYDEG
X-MailFrom: test-bounces(a)solvo.ru
X-DrWeb-SpamScore: 300
X-DrWeb-SpamState: spam
X-DrWeb-SpamDetail:
gggruggvucftvghtrhhoucdtuddrgedvvddrgedvgdduvdeiucetufdoteggodetrfcurfhrohhfihhlvgemucfftfghgfeunecuuegrihhlohhuthemuceftddtnecuogfogedtledqfeefucdlfedttddmnecujfgurhepgggtgffuhffvkfffphejfedvtdfjsehtjeertddttddvnecuhfhrohhmpehtvghsthdqohifnhgvrhesshholhhvohdrrhhunecuggftrfgrthhtvghrnheptedvledvheefueekieektdeuueeiheekffehleeuffeiteeuteelheeggfeftdfg
X-DrWeb-SpamVersion: Vade Retro 01.422.42#126 AS+AV+AP Profile: DRWEB;
Bailout: 300
X-AntiVirus: Checked by Dr.Web [MailD: 11.1.12.2108031732, SE:
11.1.7.2106242330, Core engine: 7.00.52.08270, Virus records: 10792308,
Updated: 2022-Feb-01 07:11:29 UTC]
Your authorization is required for a mailing list subscription request
approval:
For: =?utf-8?b?0JjQstCw0L0g0JrRg9C30L3QtdGG0L7QsiAo0YLQtdGB0YIp?=
<ikuznetsov(a)solvo.ru>
List: test(a)solvo.ru
=================
User greeting message has correct English body and garbled Subject as in
case 1
It seems that notifications Subject encoding is selected based on list
or user preferred language, but Subject text come from site-wide global
strings, translated to site language.
18.01.2022 20:08, Mark Sapiro wrote:
> On 1/18/22 5:31 AM, Ivan Kuznetsov wrote:
>> Hello
>>
>> There is a problem with moderator/administrator notifications used
>> national (non-acsii) characters in templates. Messages came with all
>> non-ascii chars changed to '?'
> ...
>> What am I missing in setup?
>
> Set the list's preferred language to Russian and possibly set
>
> default_language: ru
>
> in the [mailman] section of mailman.cfg.
>
--
С уважением, Иван Кузнецов
Руководитель технического отдела
Группа компаний "СОЛВО"
+7(812)60-60-555
+7(495)66-83-003
+7(921)740-72-61
http://www.solvo.ru
СОЛВО - Эталон Автоматизации Логистики
3 years, 5 months

[MM3-users] Re: Creating superuser - problem with documentation or it's just me?
by Odhiambo Washington
On Mon, 27 Jul 2020 at 02:01, Mark Sapiro <mark(a)msapiro.net> wrote:
> On 7/26/20 9:39 AM, Odhiambo Washington wrote:
> > Hi,
> >
> > In my quest to create a superuser, I followed another HOWTO -
> > https://docs.mailman3.org/en/latest/devsetup.html
> >
> > (venv) [root@gw /opt/mailman/git/mailman-suite/mailman-suite_project]#
> > python manage.py migrate
> > Traceback (most recent call last):
>
> manage.py migrate (or django-admin migrate) is part if the
> mailman-post-update script. It doesn't work here because when you run it
> this way, it doesn't get your settings.py.
>
I have taken note of that. Thank you.
> ModuleNotFoundError: No module named '_sqlite3'
>
> And it's looking for sqlite3 because that's the default database.
> > *<==============================================================*
> > (venv) [root@gw /opt/mailman/git/mailman-suite/mailman-suite_project]#
> pip
> > install pysqlite3
>
> You don't need this. You need to run django-admin with the correct
> settings.
>
Thanks for clarifying.
> So I figured out that I need to put my own settings_local.py into the
> > directory and let the command rely on MySQL as the database backend since
> > by default, it uses sqlite3 backend.
> >
> > But the question then is WHY is this not documented on the above page???
>
>
> Because that's not relevant to what you are doing. You are trying to
> install Mailman for production, not development.
>
Okay. That is true.
> > How can I delete the superuser after creating it??
>
>
> The only django-admin or manage.py you should run is
> /opt/mailman/mm/bin/djhango-admin. You can run `django-admin
> createsuperuser` to create a superuser. If you want to delete one, you
> need to go to the Django admin web UI - should be
> http://your.server/admin - login as a superuser and go to the Users page
> and delete it. You should probably do this as a different superuser
>
The reason I asked for how to delete superuser came from the fact that from
the above confusion,
I needed to create a superuser.
So now I have tried to see if there is such option from django-admin, but:
(venv) [root@gw /opt/mailman/mm]# django-admin --help
Type 'django-admin help <subcommand>' for help on a specific subcommand.
Available subcommands:
[django]
check
compilemessages
createcachetable
dbshell
diffsettings
dumpdata
flush
inspectdb
loaddata
makemessages
makemigrations
migrate
runserver
sendtestemail
shell
showmigrations
sqlflush
sqlmigrate
sqlsequencereset
squashmigrations
startapp
startproject
test
testserver
*Note that only Django core commands are listed as settings are not
properly configured (error: Requested setting INSTALLED_APPS, but settings
are not configured. You must either define the environment variable
DJANGO_SETTINGS_MODULE or call settings.configure() before accessing
settings.).*
(venv) [root@gw /opt/mailman/mm]#
So is something wrong with my settings????
I do not see the command to create the superuser listed.
My settings_local.py has got only the bits from settings.py that I have
customized.
Thank you for your patience.
--
Best regards,
Odhiambo WASHINGTON,
Nairobi,KE
+254 7 3200 0004/+254 7 2274 3223
"Oh, the cruft.", grep ^[^#] :-)
4 years, 11 months

[MM3-users] Re: Mailman3 without Hyperkitty in docker
by Abhilash Raj
Test email to check something, please ignore.
Abhilash
On Fri, Mar 1, 2019, at 5:19 PM, Abhilash Raj wrote:
>
>
> On Thu, Feb 28, 2019, at 10:18 PM, Danil Smirnov wrote:
>> Hi Abhilash,
>>
>> Thank you very much - the previous error is fixed now.
>>
>> But I have another one now, which causes the same 500 Server Error:
>>
>> bash-4.3# cat /opt/mailman-web-data/logs/uwsgi-error.log
>> *** Starting uWSGI 2.0.18 (64bit) on [Fri Mar 1 05:42:09 2019] ***
>> compiled with version: 6.3.0 on 01 March 2019 01:52:42
>> os: Linux-3.10.0-693.11.1.el7.x86_64 #1 SMP Mon Dec 4 23:52:40 UTC 2017
>> nodename: mailman-web
>> machine: x86_64
>> clock source: unix
>> detected number of CPU cores: 2
>> current working directory: /opt/mailman-web
>> detected binary path: /usr/local/bin/uwsgi
>> !!! no internal routing support, rebuild with pcre support !!!
>> setgid() to 101
>> setuid() to 100
>> chdir() to /opt/mailman-web
>> your memory page size is 4096 bytes
>> detected max file descriptor number: 1048576
>> building mime-types dictionary from file /etc/mime.types...1168 entry found
>> lock engine: pthread robust mutexes
>> thunder lock: disabled (you can enable it with --thunder-lock)
>> uwsgi socket 0 bound to TCP address 0.0.0.0:8080 fd 8
>> uwsgi socket 1 bound to TCP address 0.0.0.0:8000 fd 9
>> Python version: 3.6.8 (default, Jan 30 2019, 23:58:16) [GCC 6.3.0]
>> Python main interpreter initialized at 0x55a2df7f57e0
>> python threads support enabled
>> your server socket listen backlog is limited to 100 connections
>> your mercy for graceful operations on workers is 60 seconds
>> mapped 166752 bytes (162 KB) for 2 cores
>> *** Operational MODE: threaded ***
>> Traceback (most recent call last):
>> File "/usr/local/lib/python3.6/site-packages/django/utils/module_loading.py", line 20, in import_string
>> return getattr(module, class_name)
>> AttributeError: module 'django.contrib.auth.middleware' has no attribute 'SessionAuthenticationMiddleware'
>>
>> The above exception was the direct cause of the following exception:
>>
>> Traceback (most recent call last):
>> File "wsgi.py", line 38, in <module>
>> application = get_wsgi_application()
>> File "/usr/local/lib/python3.6/site-packages/django/core/wsgi.py", line 13, in get_wsgi_application
>> return WSGIHandler()
>> File "/usr/local/lib/python3.6/site-packages/django/core/handlers/wsgi.py", line 136, in __init__
>> self.load_middleware()
>> File "/usr/local/lib/python3.6/site-packages/django/core/handlers/base.py", line 34, in load_middleware
>> middleware = import_string(middleware_path)
>> File "/usr/local/lib/python3.6/site-packages/django/utils/module_loading.py", line 24, in import_string
>> ) from err
>> ImportError: Module "django.contrib.auth.middleware" does not define a "SessionAuthenticationMiddleware" attribute/class
>> unable to load app 0 (mountpoint='') (callable not found or import error)
>> *** no app loaded. going in full dynamic mode ***
>> *** uWSGI is running in multiple interpreter mode ***
>> spawned uWSGI master process (pid: 1)
>> spawned uWSGI worker 1 (pid: 37, cores: 2)
>> --- no python application found, check your startup logs for errors ---
>> --- no python application found, check your startup logs for errors ---
>> --- no python application found, check your startup logs for errors ---
>> --- no python application found, check your startup logs for errors ---
>> --- no python application found, check your startup logs for errors ---
>> --- no python application found, check your startup logs for errors ---
>> --- no python application found, check your startup logs for errors ---
>> --- no python application found, check your startup logs for errors ---
>> --- no python application found, check your startup logs for errors ---
>> --- no python application found, check your startup logs for errors ---
>> --- no python application found, check your startup logs for errors ---
>> --- no python application found, check your startup logs for errors ---
>>
>> As per my investigation, this error possibly caused by Django upgrade:
>>
>> *The SessionAuthenticationMiddleware class is removed. It provided no functionality since session authentication is unconditionally enabled in Django 1.10.*
>>
>> See https://docs.djangoproject.com/en/2.0/releases/2.0/
>>
>> After I've removed the line
>> https://github.com/maxking/docker-mailman/blob/master/postorius/mailman-web…
>> from settings.py, the container is finally working.
>>
>> I've placed PR in github:
>> https://github.com/maxking/docker-mailman/pull/314
>
> Thank you for your contributions!
>
> I have merged your pull request and it should now be out (hopefully!).
>
>>
>> Thank you for your help.
>>
>> Danil
>>
>>
>> пт, 1 мар. 2019 г. в 04:33, Abhilash Raj <maxking(a)asynchronous.in>:
>>>
>>>
>>> On Thu, Feb 28, 2019, at 5:19 PM, Abhilash Raj wrote:
>>> > On February 27, 2019 11:53:34 PM PST, Danil Smirnov <danil(a)smirnov.la> wrote:
>>> > >Hi Mark,
>>> > >
>>> > >Actually all this stuff happens inside the container after it's started
>>> > >and
>>> > >initialized without errors. I didn't amend the image anyhow.
>>> > >
>>> > >Also I have the configuration based on docker-compose.yaml provided in
>>> > >the
>>> > >repository which works just fine for mailman-web image.
>>> > >
>>> > >The very same config with postorius image (+ UWSGI_STATIC_MAP param)
>>> > >fails
>>> > >with 500 error...
>>> > >
>>> > >Now answering your questions:
>>> > >
>>> > >ср, 27 февр. 2019 г., 22:56 Mark Sapiro <mark(a)msapiro.net>:
>>> > >
>>> > >> do you have django-q in INSTALLED_APPS in your Django settings and
>>> > >what
>>> > >> is set for Q_CLUSTER?
>>> > >>
>>> > >
>>> > >I've checked settings.py inside the container and I haven't found any
>>> > >of
>>> > >the mentioned configurations there.
>>> > >
>>> > >Does the manage.py that's being run here point to the right
>>> > >settings.py?
>>> > >>
>>> > >
>>> > >No clue.
>>> > >
>>> > >Also I wonder why we have some Hyperkitty-related cronjobs in non-HK
>>> > >configured image?
>>> > >
>>> > >https://github.com/maxking/docker-mailman/blob/master/postorius/mailman-web…
>>> >
>>> > Because I am a dum dum ;-)
>>> >
>>> > Will work on removing those crons and stuff. Would be nice if you
>>> > opened an issue on Github so that I don't forget.
>>>
>>> Should now be fixed in the latest image.
>>>
>>> >
>>> > >Danil
>>> > >
>>> > >
>>> > >
>>> > >> --
>>> > >> Mark Sapiro <mark(a)msapiro.net> The highway is for gamblers,
>>> > >> San Francisco Bay Area, California better use your sense - B.
>>> > >Dylan
>>> > >> _______________________________________________
>>> > >> Mailman-users mailing list -- mailman-users(a)mailman3.org
>>> > >> To unsubscribe send an email to mailman-users-leave(a)mailman3.org
>>> > >> https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/
>>> > >>
>>> > >_______________________________________________
>>> > >Mailman-users mailing list -- mailman-users(a)mailman3.org
>>> > >To unsubscribe send an email to mailman-users-leave(a)mailman3.org
>>> > >https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/
>>> >
>>> >
>>> > --
>>> > Sent from my Android device with K-9 Mail. Please excuse my brevity.
>>>
>>> --
>>> thanks,
>>> Abhilash Raj (maxking)
>
> --
> thanks,
> Abhilash Raj (maxking)
>
>
--
thanks,
Abhilash Raj (maxking)
6 years, 4 months

[MM3-users] Re: hyperkitty failed to create a thread
by tlhackque
On 11-Feb-19 17:08, Marvin Gülker wrote:
> Hi,
>
> Am 11. Februar 2019 um 13:20 Uhr -0800 schrieb Mark Sapiro:
>> I downloaded the February mbox from
>> <https://wlug.mailman3.com/hyperkitty/list/wlug@lists.wlug.org/export/wlug@l…>
>> and imported it to a test list with 'django-admin hyperkitty_import and
>> see the same issue.
> Here's the Hyperkitty Mbox for my affected mailinglist:
> <https://lists.secretchronicles.org/hyperkitty/list/tsc-devel@lists.secretch…>
>
> Maildir from my local machine as received from Mailman via e-mail:
> <https://files.guelker.eu/misc/tsc-devel.tar.gz>
>
>> Examination of the mbox shows for the first message [...]
>> Note the folding of the header and the double angle brackets.
> I can confirm that I see this behaviour for my affected mailinglist as
> well. The Message-ID header is broken over two lines with double angle
> brackets in the Hyperkitty MBox linked above:
>
> Message-ID: <
> <153582973006.27514.7508703206376217479(a)alexandria.secretchronicles.org>>
>
> However, the original message as it was delivered by Mailman to me does
> not have such a weird message-id header:
>
> Message-ID:
> <153582973006.27514.7508703206376217479(a)alexandria.secretchronicles.org>
>
> In this message, the header is broken exactly as shown above after the
> colon of "Message-ID:". Maybe some problem with parsing long Message-ID
> headers, or ones folded over multiple lines?
>
> With regard to bug reporting on gitlab.com: I already have accounts on a
> ton of sites, and at some point I'd actually like to stop creating new
> ones all the time...
>
> Marvin
>
The double angle brackets are a problem.
The folding is legal. Any whitespace in a header (not inside tokens,
such as quoted strings, of course) can be replaced by a <CR><LF><one
whitespace character> So
Message-ID: <glorp>
is identical to
Message-ID:
<glorp>
(See RFC2822 3.2.3 for a more precise explanation)
A message-ID within <<>> is not valid; whatever generated it has a bug.
RFC2822 grammar
message-id = "Message-ID:" msg-id CRLF
in-reply-to = "In-Reply-To:" 1*msg-id CRLF
references = "References:" 1*msg-id CRLF
msg-id = [CFWS] "<" id-left "@" id-right ">" [CFWS]
id-left = dot-atom-text / no-fold-quote / obs-id-left
id-right = dot-atom-text / no-fold-literal / obs-id-right
no-fold-quote = DQUOTE *(qtext / quoted-pair) DQUOTE
no-fold-literal = "[" *(dtext / quoted-pair) "]"
specials = "(" / ")" / ; Special characters used in
"<" / ">" / ; other parts of the syntax
"[" / "]" /
":" / ";" /
"@" / "\" /
"," / "." /
DQUOTE
atext = ALPHA / DIGIT / ; Any character except controls,
"!" / "#" / ; SP, and specials.
"$" / "%" / ; Used for atoms
"&" / "'" /
"*" / "+" /
"-" / "/" /
"=" / "?" /
"^" / "_" /
"`" / "{" /
"|" / "}" /
"~"
atom = [CFWS] 1*atext [CFWS]
dot-atom = [CFWS] dot-atom-text [CFWS]
dot-atom-text = 1*atext *("." 1*atext)
6 years, 4 months

[MM3-users] Re: FYI: Django security releases issued: 4.0.6 and 3.2.14
by David Newman
On 7/7/22 3:35 PM, Mark Sapiro wrote:
> On 7/7/22 3:09 PM, David Newman wrote:
>>
>> I *think* the command runs if I escape the hyphen:
>>
>> root@somehost:/opt/mailman/venv/lib/python3.9/site-packages# grep -r
>> '\-jango' /opt/mailman/venv/lib/python3.9/site-packages/
>>
>> But then that doesn't return anything.
>
> Yes, escaping the hyphen is the correct thing to do. You could also try
> something like
> ```
> grep -r '.-jango' /opt/mailman/venv/lib/python3.9/site-packages/
> ```
> but that will also return nothing.
>
> See
> https://stackoverflow.com/questions/67613777/pip-ignoring-invalid-distribut…
> https://stackoverflow.com/questions/68880743/why-do-i-get-this-when-using-p…
> and perhaps other hits from
> https://www.google.com/search?q=pip+warning+ignoring+invalid+distribution
>
> Look for
> ```
> ls -la /opt/mailman/venv/lib/python3.9/site-packages/~jango*
> ```
> i.e. `~jango` rather than `-jango`
Interesting -- that does produce two directories with names starting
with a tilde:
/opt/mailman/venv/lib/python3.9/site-packages/~jango:
total 100
drwxr-xr-x 19 root root 4096 Jul 7 10:56 .
drwxr-xr-x 188 mailman mailman 12288 Jul 7 12:38 ..
drwxr-xr-x 3 root root 4096 Jul 7 10:56 apps
drwxr-xr-x 3 root root 4096 Jul 7 10:56 bin
drwxr-xr-x 7 root root 4096 Jul 7 10:56 conf
drwxr-xr-x 18 root root 4096 Jul 7 10:56 contrib
drwxr-xr-x 11 root root 4096 Jul 7 10:56 core
drwxr-xr-x 6 root root 4096 Jul 7 10:56 db
drwxr-xr-x 3 root root 4096 Jul 7 10:56 dispatch
drwxr-xr-x 5 root root 4096 Jul 7 10:56 forms
drwxr-xr-x 3 root root 4096 Jul 7 10:56 http
-rw-r--r-- 1 root root 800 Jul 7 10:56 __init__.py
-rw-r--r-- 1 root root 211 Jul 7 10:56 __main__.py
drwxr-xr-x 3 root root 4096 Jul 7 10:56 middleware
drwxr-xr-x 2 root root 4096 Jul 7 10:56 __pycache__
-rw-r--r-- 1 root root 4896 Jul 7 10:56 shortcuts.py
drwxr-xr-x 5 root root 4096 Jul 7 10:56 template
drwxr-xr-x 3 root root 4096 Jul 7 10:56 templatetags
drwxr-xr-x 3 root root 4096 Jul 7 10:56 test
drwxr-xr-x 3 root root 4096 Jul 7 10:56 urls
drwxr-xr-x 4 root root 4096 Jul 7 10:56 utils
drwxr-xr-x 6 root root 4096 Jul 7 10:56 views
/opt/mailman/venv/lib/python3.9/site-packages/~jango-3.0.14.dist-info:
total 500
drwxr-xr-x 2 root root 4096 Jul 7 10:56 .
drwxr-xr-x 188 mailman mailman 12288 Jul 7 12:38 ..
-rw-r--r-- 1 root root 36843 Jul 7 10:56 AUTHORS
-rw-r--r-- 1 root root 83 Jul 7 10:56 entry_points.txt
-rw-r--r-- 1 root root 4 Jul 7 10:56 INSTALLER
-rw-r--r-- 1 root root 1552 Jul 7 10:56 LICENSE
-rw-r--r-- 1 root root 13231 Jul 7 10:56 LICENSE.python
-rw-r--r-- 1 root root 3625 Jul 7 10:56 METADATA
-rw-r--r-- 1 root root 415583 Jul 7 10:56 RECORD
-rw-r--r-- 1 root root 7 Jul 7 10:56 top_level.txt
-rw-r--r-- 1 root root 92 Jul 7 10:56 WHEEL
Going back to the original warning:
(venv) mailman@somehost:/home/dnewman$ pip show mailman-web
WARNING: Ignoring invalid distribution -jango
(/opt/mailman/venv/lib/python3.9/site-packages)
Name: mailman-web
..
The warning goes away after moving those two tilde directories out of
the way. Is it safe to delete them?
Thanks again.
dn
2 years, 11 months

[MM3-users] Re: spanish localization
by Victoriano Giralt
On Thu, 2021-02-11 at 11:15 -0800, Mark Sapiro wrote:
> For Mailman core you need to run
>
> ```
> cd mailman/messages/es/LC_MESSAGES
> msgfmt -o mailman.mo mailman.po
>
> ```
> to compile the mailman.po file for gettext.
Mark, I'd say the Mailman core message files taht get installed by pip
are "a bit outdated" (source files dates point to a nightly build) ...
proof here:
[root@isoc-es messages]# pwd
/usr/local/lib/python3.6/site-packages/mailman/messages
[root@isoc-es messages]# ll */LC*/
ca/LC_MESSAGES/:
total 164
-rw-r--r-- 1 root root 66479 Feb 3 02:47 mailman.mo
-rw-r--r-- 1 root root 95099 Oct 30 17:30 mailman.po
de/LC_MESSAGES/:
total 184
-rw-r--r-- 1 root root 81693 Feb 3 02:47 mailman.mo
-rw-r--r-- 1 root root 104049 Jan 17 20:41 mailman.po
en/LC_MESSAGES/:
total 172
-rw-r--r-- 1 root root 74350 Feb 3 02:47 mailman.mo
-rw-r--r-- 1 root root 97233 Oct 30 17:30 mailman.po
eo/LC_MESSAGES/:
total 60
-rw-r--r-- 1 root root 321 Feb 3 02:47 mailman.mo
-rw-r--r-- 1 root root 55254 Oct 30 17:30 mailman.po
es/LC_MESSAGES/:
total 184
-rw-r--r-- 1 root root 80741 Feb 12 09:18 mailman.mo
-rw-r--r-- 1 root root 102963 Nov 7 01:50 mailman.po
fr/LC_MESSAGES/:
total 124
-rw-r--r-- 1 root root 42261 Feb 3 02:47 mailman.mo
-rw-r--r-- 1 root root 81452 Jan 17 20:41 mailman.po
he/LC_MESSAGES/:
total 180
-rw-r--r-- 1 root root 79940 Feb 3 02:47 mailman.mo
-rw-r--r-- 1 root root 101264 Jan 17 19:20 mailman.po
hu/LC_MESSAGES/:
total 72
-rw-r--r-- 1 root root 9500 Feb 3 02:47 mailman.mo
-rw-r--r-- 1 root root 59290 Feb 3 02:44 mailman.po
it/LC_MESSAGES/:
total 180
-rw-r--r-- 1 root root 78543 Feb 3 02:47 mailman.mo
-rw-r--r-- 1 root root 100864 Jan 17 20:41 mailman.po
ja/LC_MESSAGES/:
total 60
-rw-r--r-- 1 root root 1296 Feb 3 02:47 mailman.mo
-rw-r--r-- 1 root root 55755 Oct 30 17:30 mailman.po
ko/LC_MESSAGES/:
total 164
-rw-r--r-- 1 root root 66668 Feb 3 02:47 mailman.mo
-rw-r--r-- 1 root root 94598 Oct 30 17:30 mailman.po
nb_NO/LC_MESSAGES/:
total 68
-rw-r--r-- 1 root root 6263 Feb 3 02:47 mailman.mo
-rw-r--r-- 1 root root 57744 Jan 17 19:20 mailman.po
pl/LC_MESSAGES/:
total 60
-rw-r--r-- 1 root root 1933 Feb 3 02:47 mailman.mo
-rw-r--r-- 1 root root 56068 Oct 30 17:30 mailman.po
pt/LC_MESSAGES/:
total 60
-rw-r--r-- 1 root root 1734 Feb 3 02:47 mailman.mo
-rw-r--r-- 1 root root 55963 Oct 30 17:30 mailman.po
ru/LC_MESSAGES/:
total 80
-rw-r--r-- 1 root root 12651 Feb 3 02:47 mailman.mo
-rw-r--r-- 1 root root 62127 Oct 30 17:30 mailman.po
sq/LC_MESSAGES/:
total 60
-rw-r--r-- 1 root root 321 Feb 3 02:47 mailman.mo
-rw-r--r-- 1 root root 55227 Oct 30 17:30 mailman.po
tr/LC_MESSAGES/:
total 168
-rw-r--r-- 1 root root 73537 Feb 3 02:47 mailman.mo
-rw-r--r-- 1 root root 96452 Jan 17 20:41 mailman.po
zh_Hans/LC_MESSAGES/:
total 64
-rw-r--r-- 1 root root 4945 Feb 3 02:47 mailman.mo
-rw-r--r-- 1 root root 57269 Jan 17 19:20 mailman.po
--
Victoriano Giralt Innovation Director
Digital Transformation Vicerectorate University of Malaga
+34952131415 SPAIN
==================================================================
Note: signature.asc is the electronic signature of present message
A: Yes.
> Q: Are you sure ?
>> A: Because it reverses the logical flow of conversation.
>>> Q: Why is top posting annoying in email ?
4 years, 4 months

[MM3-users] Re: OS upgrade - anything to take care of?
by Ruth Ivimey-Cook
On 13/05/2021 20:06, Mark Sapiro wrote:
> On 5/13/21 11:28 AM, Ruth Ivimey-Cook wrote:
> Yes, I overlooked some aspects of virtualenv. Actually, the Python in
> the virtualenv is mostly symlinks to the Python it was built with, so
> whether it continues to work after a Python upgrade depends on what the
> symlinks are and how the Python upgrade installs.
Correct.
>
>> I would therefore appreciate some guidance on performing the upgrade
>> from 3.6 to 3.8 with the minimum of fuss.
>>
>> [I am not sure, but it could be possible to install python3.8 while
>> using Ubuntu 18, so that the dist upgrade never breaks anything. Worth
>> exploring.]
> I haven't tested any of this, but I suspect if Python is for example,
> /usr/bin/python3.6 and /usr/lib/python3.6 the upgrade removes those and
> installs /usr/bin/python3.8 and /usr/lib/python3.8, that you could just
> create symlinks from /usr/bin/python3.6 and /usr/lib/python3.6 to
> /usr/bin/python3.8 and /usr/lib/python3.8 respectively and it would work.
It would be nice if that worked, and I tried it, but it doesn't work
because the python system and site directories under ./lib are also
versioned (eg ./lib/python3.6/site-packages), so you would have to
additionally create symlinks for those and/or rebuild those.
> On the other hand, if the symlinks in the venv are to things like
> /usr/bin/python3 and /usr/lib/python3 which used to point to 3.6
> versions and after upgrade point to 3.8 versions, it should just work.
Sadly they aren't - they link to python3.6 or whatever... and even if
not, the /lib/ naming gets you as well.
And even if that can be worked around (eg by renaming the mailman
/lib/python3.6 folder to /lib/python3.8), the python .pyc files are
/also/ versioned, so you then have to find & delete them all to force
the new interpreter to rebuild them or python falls down in a heap.
> As far as installing Python3.8 on Ubuntu 18.04 goes, the machine I'm
> typing this on is Ubuntu 18.04 and has 6 different Python3 versions
>
> mark@msapiro:~$ /usr/bin/python3.5 --version
> Python 3.5.2
> mark@msapiro:~$ /usr/bin/python3.6 --version
> Python 3.6.9
> mark@msapiro:~$ /usr/local/bin/python3.6 --version
> Python 3.6.12
> mark@msapiro:~$ /usr/local/bin/python3.7 --version
> Python 3.7.9
> mark@msapiro:~$ /usr/local/bin/python3.8 --version
> Python 3.8.7
> mark@msapiro:~$ /usr/local/bin/python3.9 --version
> Python 3.9.1
>
> and /usr/bin/python3 is a symlink to /usr/bin/python3.6 and
> /usr/local/bin/python3 is a symlink to /usr/local/bin/python3.9, so take
> your pick...
Indeed... and it would be lovely if it was that simple, but my
experience was that even if you got a good python executable running,
the other versioned elements of a python install caused it to mess up.
What worked for me in the end was a combination of forcing a complete
rebuild/reinstall with the mailman3 python3.8 install, followed by a bit
of rejigging of file permissions and settings (probably because I'd
messed something up, but maybe not).
Regards
Ruth
--
Software Manager & Engineer
Tel: 01223 414180
Blog: http://www.ivimey.org/blog
LinkedIn: http://uk.linkedin.com/in/ruthivimeycook/
4 years, 1 month

[MM3-users] Re: configuring postfix local recipient table
by Stephen J. Turnbull
Alexander Inzinger-Zrock writes:
> It seems i set both *facepalm* while doing [1] and then adding
> changes according to [2]:
It's OK to set both. But you need to coordinate "layout: LAYOUT" and
"[paths.LAYOUT]" if you are going to set any paths such as var_dir.
> so i have empty logs at /opt/mailman/mm/var/logs
> and populated log files under /var/tmp/mailman/logs
"var_dir: /var/tmp/mailman" is a good setting for experimenting with
Mailman 3 before you're ready for production. But you don't want
/var/tmp for production. Your logs and any queued messages will get
deleted when the system reboots (for most system configurations).
> Now - before changing the /etc/postfix/main.cfg - there is the
> question that brings us almost back to the start:
For the production system you want main.cf as it is, but change
mailman.cfg to
[mailman]
layout: local
[paths.local]
var_dir: /opt/mailman/mm/var
For an experimental system where you don't care if stuff disappears on
reboot, you can comment out the two lines for [paths.local], and
change the prefix in the *_maps variables in main.cf from
/opt/mailman/mm/var/ to /var/tmp/mailman/.
> **what is the recommended place to put the files to?**
Wherever is convenient for you! There are four predefined "selectable
layouts", paths.local, paths.dev, paths.here, and paths.fhs based on
paths.master. paths.master defines the configurable names, and some
more or less convenient defaults. In particular, it chooses a
non-destructive (because temporary) var_dir: /var/tmp/mailman, and
puts all of Mailman's data in a flat structure underneath.
paths.local is just an alias for paths.master (defined in schema.cfg).
paths.dev and paths.here are aliases for paths.master with var_dir set
relative to mailman.cfg and the current directory respectively (two
configurations some developers find convenient). paths.fhs pretty
much ignores paths.master (except that it must use the same directory
names) to put the various components in places that conform to the
Filesystem Hierarchy Standard (FHS), which makes Debian and Ubuntu
packagers happy.
You can select any of those by using the "[mailman] layout" setting
(I'm not sure if you can use "layout: master", but you're not supposed
to). You can further modify them by using the "[paths.LAYOUT]
SOME_dir" settings. In production, you almost certainly want either
paths.fhs (as is) or paths.local with a var_dir setting either in /opt
or in /var.
> and that the above specific /opt/mailman -part is just a leftover
"/opt" is not a "leftover", it's a convention where the whole package,
including programs and resources, is placed in its own hierarchy (like
a macOS application). The "var_dir: /opt/mailman/mm/var" setup is a
configuration that Mark Sapiro found convenient and continues to use.
I prefer a different layout, but if I were you I'd stick with layout:
local, var_dir: /opt/mailman/mm/var because everybody who answers
questions is familiar with it.
> If my assumption is correct i would create an issue + merge-request
> for the docs.
No, the docs are generally fine. I'll check some details later.
--
GNU Mailman consultant (installation, migration, customization)
Sirius Open Source https://www.siriusopensource.com/
Software systems consulting in Europe, North America, and Japan
2 months

[MM3-users] Re: How to delete non-users
by Allan Hansen
Hi Mike,
Yes, the users can be subscribed, but they think that they can't because it seems they are until the moderator accepts them.
I tried your script again, with nothing happening. So I tried this:
>>>
>>> a = 1
>>> b = 1
>>> for l in lm:
... print(a)
... a = a+1
... for nm in l.nonmembers.members:
... print(b)
... b = b + 1
... nm.unsubscribe()
...
>>> commit()
>>> print(a)
1
>>> print(b)
1
It appears that lm can't see the lists (I have 50+ of them).
Yours,
Allan
On 9/16/22, 15:01 , "Mark Sapiro" <mark(a)msapiro.net> wrote:
On 9/16/22 11:19, Allan Hansen wrote:
> Hi all,
>
> This is a bit of an emergency:
>
> I am getting a bunch of complaints from potential list members of my lists that they can't subscribe and they don't get messages. Apparently, the issue is that they are non-members. I have never created any non-members but looking at the docs it seems that if someone sends a message to the list, they automatically become non-members.
> For individuals I have been able to delete their non-membership and they then could subscribe properly.
I don't understand. the fact that an address is a non-member of a list
should not impact subscribing that address as a member.
> I have looked at some of my most popular lists and they have hundreds of non-members! It will take me an awful amount of time to remove each one manually, and not doing it - handling each as they complain - is also a lot of waste of time and cause of frustration for all involved.
What is actually happening when the non-member attempts to subscribe as
a member? What do they do and what it the result?
> I have tried scripting it with delmember, but it does not take the '-r nonmember' option ('findmember' does!).
>
> Can anyone help me find out how to
> a. delete all non-members of all my lists
If you have access to `mailman shell` you could do:
```
$ mailman shell
Welcome to the GNU Mailman shell
Use commit() to commit changes.
Use abort() to discard changes since the last commit.
Exit with ctrl+D does an implicit commit() but exit() does not.
>>> lm = getUtility(IListManager)
>>> for l in lm:
... for nm in l.nonmembers.members:
... nm.unsubscribe()
...
>>> commit()
```
> b. prevent MM3 from creating new non-members in the future (so I don't have to keep removing them)
nonmembers are an integral part of Mailman 3's architecture. The basic
idea is a nonmember has a moderation action and setting a nonmembers
moderation replaces MM 2.1's adding that address to one of
*_these_nonmembers (The legacy *_these_nonmembers attributes still
exist, but only to support regexps).
It would require extensive modification to not create nonmembers.
However, I still don't understand why the presence of a nonmember record
is an issue.
--
Mark Sapiro <mark(a)msapiro.net> The highway is for gamblers,
San Francisco Bay Area, California better use your sense - B. Dylan
_______________________________________________
Mailman-users mailing list -- mailman-users(a)mailman3.org
To unsubscribe send an email to mailman-users-leave(a)mailman3.org
https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/
2 years, 9 months

[MM3-users] Re: How to hide sender completely
by Roland Miyamoto
Dear Mark and everyone,
On 09/05/2023 17:12, Mark Sapiro wrote:
> Anonymous lists should be removing any X-MailFrom: or
> X-Envelope-From: headers from delivered mail. The envelope-from in
> the outgoing mail should be the list-bounces address, not the
> original sender.
> If you are seeing this information in mail from an anonymous list, it
> is a bug and I would like to see a raw message as received from the
> list with this information.
Thank you very much for replying so quickly.
At the end of this email, I include a message's header
received from one of my Mailman3 lists (renamed to ourlist here)
with the following settings in the web interface:
Alter Messages
• Filter content =Yes
• Collapse alternatives= No
• Convert html to plaintext=No
• Anonymous list= Yes
• Include RFC2369 headers= Yes
• Include the list post header = No
• First strip reply to = Yes
• Reply goes to list = Explicit Reply-to set; no Cc added
• Pipeline = default-posting-pipeline
DMARC Mitigations
• DMARC mitigation action = No DMARC mitigation
• DMARC Mitigate unconditionally = No
As you can see, the header contains the sender's address
sender(a)otherdomain.tld
twice.
Thanks for all your effort,
Roland
----------------------------
(edited) list header follows
----------------------------
From - Fri Apr 21 23:18:21 2023
X-Mozilla-Status: 0001
X-Mozilla-Status2: 00000000
X-Mozilla-Keys:
Return-Path: <ourlist-bounces(a)list.timebrain.org>
Received: from mail.timebrain.org
by mail.timebrain.org with LMTP
id Ph5sJ0XzQmSxBQAAMe3UBQ
(envelope-from <ourlist-bounces(a)list.timebrain.org>); Fri, 21 Apr 2023 22:34:13 +0200
Received: from timebrain.org (localhost [IPv6:::1])
by mail.timebrain.org (Postfix) with ESMTP id 9110FC0082;
Fri, 21 Apr 2023 22:34:13 +0200 (CEST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=list.timebrain.org;
s=202205; t=1682109253;
bh=KEcouWpeNLb32k6bFssIJDhe16IGlOZEsBeJOIigkLs=;
h=Date:To:In-Reply-To:References:From:Reply-To:Subject:List-Id:
List-Help:List-Post:List-Subscribe:List-Unsubscribe:From;
b=MmI/E0AHnIway3V//e0KNbYj06VBWcDKGMlK4yA+tPGmgCAnje4NwZM9YXbZk/hc7
FKM8O1RRkfUhC6iCUHMQa28XK4Nr9+45G/Yxl7Tgr8h6qt1B/1myOCLS8Mb+4XSwpm
CuShRI812x7GkCWVqpLoRBKwq4CP8j8BdDgN4rmrUF18Mdh0J/kkccV13dJvG9xapB
XzUkpqcJICWNyQ/1+GY59VEISP3EBQxUzg6Qkd6a4BXkPKNPCRzVUVM0irvQ0nLi8Z
nAKnV7iutn5nKMXOkEfX5K+8HuFm2Ixd1cWnSIfPY7gd0WK0DyjLVgsZIINA6Hnwt5
9fABm1Dsr6YeQ==
Received: from mail.timebrain.org (localhost [127.0.0.1])
by mail.timebrain.org (Postfix) with ESMTP id C912FC0082
for <ourlist(a)list.timebrain.org>; Fri, 21 Apr 2023 22:34:11 +0200 (CEST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=demonetize.it;
s=201907; t=1682109251;
bh=799sMT9Q1QA5X8QRdz/ErDUnITC5MNct/qLMzA5zPSA=;
h=Date:From:To:Subject:In-Reply-To:References:From;
b=KKp8OdYRcEStg4A3qhDgKm4fJQg8U6xPL9w1jbcNJ3BozX8QKqg3NqVC6cbcptHtr
9tUzsc1WBCYy1UHH7UOCFXowfNtRu+KlvT8YpBNeGgsa12nZ4Ljhw7IRuENcp1sqyj
tnZWWRW8T+wcsJlftOhcCudT59gq1LilZIEPpDNGJ63jgJIX5838IBaz2cXZyHQAWd
XMF6uTz/xc5sRutPHWOUtRETHySK0PEI59cpkRz1UvHwDu1opliv4ILZmR4BW32T6a
OeK06uv6uhRfH8Gc420zhkp+tYSgUc28Z4G93uDC12MypmKshnsZiR52MUFZp1JM8X
eJGEpnGP7xHew==
Received: from [IPv6:::1] ([2a02:560:4ca5:ea00:5c9f:6282:e0ec:582])
by mail.timebrain.org with ESMTPSA
id zuaKLUPzQmSnBQAAMe3UBQ
(envelope-from <sender(a)otherdomain.tld>)
for <ourlist(a)list.timebrain.org>; Fri, 21 Apr 2023 22:34:11 +0200
Date: Fri, 21 Apr 2023 22:31:08 +0200
To: Ourlist Ourtown <ourlist(a)list.timebrain.org>
User-Agent: K-9 Mail for Android
In-Reply-To: <a8c92d51-66c2-2588-f00c-31146bee2f54(a)timebrain.org>
References: <3e35f420-a766-095e-b79a-afb8e795f011(a)timebrain.org> <a8c92d51-66c2-2588-f00c-31146bee2f54(a)timebrain.org>
Message-ID: <7AB6FFA2-BDA7-4484-BF14-4CF512A4B8E8(a)demonetize.it>
MIME-Version: 1.0
Message-ID-Hash: 7IYNX33ESBTJZ3M4FGHGGVDBTZ3HGL2B
X-Message-ID-Hash: 7IYNX33ESBTJZ3M4FGHGGVDBTZ3HGL2B
X-MailFrom: sender(a)otherdomain.tld
X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; suspicious-header
From: Our List <ourlist(a)list.timebrain.org>
X-Mailman-Version: 3.2.1
Precedence: list
Reply-To: Ourlist Ourtown <ourlist(a)list.timebrain.org>
Subject: [Ourlist] Re: whatever was the topic
List-Id: Our List <ourlist.list.timebrain.org>
List-Help: <mailto:ourlist-request@list.timebrain.org?subject=help>
List-Post: NO
List-Subscribe: <mailto:ourlist-join@list.timebrain.org>
List-Unsubscribe: <mailto:ourlist-leave@list.timebrain.org>
Content-Type: multipart/mixed; boundary="===============6841522137146215921=="
--===============6841522137146215921==
Content-Type: multipart/alternative;
boundary=----F0JANJPGLDOAM8SUMOY3TD9QT0ZRGF
Content-Transfer-Encoding: 7bit
------F0JANJPGLDOAM8SUMOY3TD9QT0ZRGF
Content-Type: text/plain;
charset=utf-8
Content-Transfer-Encoding: quoted-printable
2 years, 1 month

[MM3-users] Re: old usernames appearing in mailman.log
by Ken Alker
--On Sunday, June 25, 2023 1:14 PM -0700 Mark Sapiro <mark(a)msapiro.net>
wrote:
> On 6/25/23 11:04 AM, Ken Alker wrote:
>>
>> I've just taken on the project so I'm new to all of this, and one thing
>> I noticed that caught my eye, and has left me curious, is that for the
>> first a couple of seconds starting just after midnight every night (just
>> after log rotation) mailman.log would have many (dozens, or hundreds) of
>> lines entered in it just like this one:
>>
>> Jun 19 00:00:04 2023 (2266) 127.0.0.1 - - "GET
>> /3.0/users/old-user(a)domain.tld HTTP/1.1" 404 58
>>
>> where "old-user(a)domain.tld" is the email address of a user who either
>> had unsubscribed or changed their email address (I don't know which, I
>> just know they are no longer a member/subscriber to the list). Each
>> successive entry in the log would have a different "old username" in it.
>> I don't understand why these entries would be in the log and what they
>> mean. Can someone shed some light on this for me? This is merely a
>> question of curiosity, and not one of import. (Since migrating from
>> 3.2.2 to 3.3.8 this behavior has stopped, be that GOOD or BAD.)
>
>
> This is the Django hyperkitty sync_mailman job which is one of the django
> admin jobs run daily. It goes through the HyperKitty 'sender' database
> table and tries to find the Mailman core user id for each sender address
> to add/update its mailman_id field with core's user_id.
>
> The 404s are addresses im HyperKitty's sender table for whih there is no
> corresponding Mailman user. There are multiple possible reasons for this.
And that is OK, right?
> If the behavior has stopped it's probably because the periodic Django
> jobs are not being run - this is bad.
I see this in the logs from just after midnight:
Jun 25 00:13:04 2023 (386086) No cached copy of the public suffix list found
Jun 25 00:13:04 2023 (386086) ACCEPT:
<7500f0e2-1ae1-309d-60d7-6e592c7abf7a(a)west.net>
Jun 25 00:13:04 2023 (386090) HyperKitty failure on
https://lists.netlojix.com/hyperkitty/api/mailman/urls:
Followed by a huge amount of HTML (strange).
I'm not sure if the first and last (third) lines in the log excerpt above
are due to the same thing. I know why the public suffix list is not found;
when I was migrating all my queues from the Debian layout to the "source
install" layout, I could not figure out where it should go in the new world
order. Can you tell me where it would normally be found on a fresh source
install? I'll move it there.
Is there a way to kick it into re-running whatever it does at midnight so I
can test this again after putting the public suffix list back? I assume I
can just execute "mailman-web runjobs daily", but will this mess things up,
or is it OK to run it mid-day without stopping anything first?
Is the last (third) log line excerpt simply a result of the first, or do I
have something else messed up?
Thank you!
Ken
2 years

[MM3-users] Re: mm3 installation question
by Odhiambo Washington
On Wed, Mar 6, 2024 at 12:13 PM Stephen J. Turnbull <
turnbull.stephen.fw(a)u.tsukuba.ac.jp> wrote:
> Odhiambo Washington writes:
>
> > Mark Sapiro writes:
>
> > > Some of the `path` settings are probably not in the same order as
> > > in that file. The
> > >
> > > ```
> > > path('mailman3/', include('postorius.urls')),
> > > path('archives/', include('hyperkitty.urls')),
> > > ```
> > > settings should come after the
> > > ```
> > > path('postorius/', include('postorius.urls')),
> > > path('hyperkitty/', include('hyperkitty.urls')),
> > > ```
> > > settings (unfortunately, mailman-web 0.0.8 has these in the wrong
> > > order). Or you can just delete the 'postorius/' and 'hyperkitty/'
> > > ones or you can add
> > > ```
> > > ProxyPass "/postorius" "http://127.0.0.1:8000/postorius"
> > > ProxyPass "/hyperkitty" "http://127.0.0.1:8000/hyperkitty"
> > > ```
> > > to your Apache config.
>
> > The odd thing is that the HOWTO that he followed never involves the
> > manipulation of any urls.py at all - it's not even mentioned at any
> > point. So obviously the issue is caused by something else and I
> > suspect something within Apache needs to be re-evaluated in the
> > guide.
>
> I believe this is the Apache configuration the OP is using:
>
> <IfModule mod_proxy.c>
> ProxyPreserveHost On
> ProxyPass "/mailman3" "http://127.0.0.1:8000/mailman3"
> ProxyPass "/archives" "http://127.0.0.1:8000/archives"
> ProxyPass "/accounts" "http://127.0.0.1:8000/accounts"
> ProxyPass "/admin" "http://127.0.0.1:8000/admin"
> ProxyPass "/user-profile" "http://127.0.0.1:8000/user-profile"
> </IfModule>
>
> Note that Apache doesn't know about the "/postorius" and "/hyperkitty"
> URI paths. It is quite unclear to me how this works at all with
> either the
>
> path('mailman3/', include('postorius.urls')),
> path('archives/', include('hyperkitty.urls')),
> path('postorius/', include('postorius.urls')),
> path('hyperkitty/', include('hyperkitty.urls')),
>
> version of urls.py or the reverse order version
>
> path('postorius/', include('postorius.urls')),
> path('hyperkitty/', include('hyperkitty.urls')),
> path('mailman3/', include('postorius.urls')),
> path('archives/', include('hyperkitty.urls')),
>
> I think Mark must have a configuration with
>
> ProxyPass "/" "http://127.0.0.1:8000/"
>
> in the Apache configuration in mind? Or an alias or rewrite rule.
> Otherwise I don't see how "/postorius" and "/hyperkitty" paths ever
> get transmitted to the WSGI server.
>
My thinking then is that the documentation at
https://docs.list.org/en/latest/install/virtualenv.html#apache-configuration
needs to be fixed by adding the missing bits,
or a urls.py be provided for inclusion in /etc/mailman3/ and which
sysadmins can edit to their liking. For example, I'd prefer to have /mm3
instead of /mailman3 to save on transmitted bytes and not clog the Internet
pipes :-)
--
Best regards,
Odhiambo WASHINGTON,
Nairobi,KE
+254 7 3200 0004/+254 7 2274 3223
In an Internet failure case, the #1 suspect is a constant: DNS.
"Oh, the cruft.", egrep -v '^$|^.*#' ¯\_(ツ)_/¯ :-)
[How to ask smart questions:
http://www.catb.org/~esr/faqs/smart-questions.html]
1 year, 3 months

[MM3-users] Re: only show mail domains from web host on web-host-url
by Jens Günther
Thank you for the clarification!
Am 19.03.21 um 18:48 schrieb Abhilash Raj:
>
>
>> On Mar 19, 2021, at 6:38 AM, Jens Günther <jens.guenther(a)posteo.de> wrote:
>>
>> Thank you for your answer. I should have seen that in the Docs, but somehow missed it: https://docs.mailman3.org/en/new/prodsetup.html
>
> You seem to have landed on a very old version of the docs that I didn’t unfortunately knew
> was even available. I have disabled that page now.
>
> The settings are documented in https://docs.mailman3.org/en/latest/config-web.html
>
>>
>> I set it in the corresponding file, but unfortunately it doesn't work :-( I tried other setting to prove, that the file is used (ALLOWED_HOSTS works, changed here from '*' to 'localhost' and my example-domains, this works). It seems to be the same as this user describes (a while ago): https://lists.mailman3.org/archives/list/mailman-users@mailman3.org/thread/…
>>
>> How could I check, that the setting is used!?
>>
>> But maybe some additional information:
>> - I use the Debian installation on a stable buster, so mailman is version 3.2.1
>> - I use apache2 as my web-server and use the given alias-conf-file
>> - Python is version 3.7.3
>> - Postorius is Version 1.2.4
>> - HyperKitty is version 1.2.2
>>
>> -> In Django admin-Panel (/mailman3/admin/) I added 2 Websites test1.xyz.de and test2.xyz.de
>> -> In Postorius (/mailman3/postorius/domains/) I added 2 Domains as Mail Hosts test1.xyz.de and test2.xyz.de with the corresponding Web hosts as stated above
>> -> I added 1 list (/mailman3/postorius/lists/) for each Mail Domain as follows: test1(a)test1.xyz.de and test2(a)test2.xyz.de
>> -> then created a vhost in apache2 with SSL-cert and added the Domains in ALLOWED_HOSTS: test1.xyz.de and test2.xyz.de
>> -> When I go to the 2 Testdomains (corresponding web hosts), I see on each both lists for the different Mail domains
>>
>> What do I miss? Or where to investigate?
>>
>> Thank you in advance, best regards.
>>
>> By the way: what'S the difference in the 2 docs? https://docs.mailman3.org/en/latest/index.html and https://mailman.readthedocs.io/en/latest/README.html
>
> Mailman Suite consists of several individual projects including Mailman Core, Postorius (Web UI) and
> Hyperkitty (Archiver). The first URL is the landing page for the entire suite and should direct you to
> individual projects. The second one is the individual Mailman Core project. Historically, Core was the
> only project and hence claims the name “mailman” in most places.
>
>>
>> Am 18.03.21 um 21:52 schrieb Mark Sapiro:
>>> On 3/18/21 9:20 AM, jens.guenther(a)posteo.de wrote:
>>>> Is it possible, to only show publicly (if advertised) these lists on a certain url, that are corresponding to the web host the url I accessed mailman through?
>>> Set FILTER_VHOST = True in your settings_local.py or where ever you put
>>> your site Django settings.
>> _______________________________________________
>> Mailman-users mailing list -- mailman-users(a)mailman3.org
>> To unsubscribe send an email to mailman-users-leave(a)mailman3.org
>> https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/
>
4 years, 3 months

[MM3-users] Re: Thread IDs on messages incrementing per reply?
by Thomas Ward
On 10/18/23 20:25, Mark Sapiro wrote:
> On 10/18/23 15:06, Thomas Ward via Mailman-users wrote:
>> Is there a way to oerhaps custom-plugin my way through to set this up
>> as an integration into Core? And specify the custom handler process
>> or such to allow that integration? I see that there are ways to code
>> plugins into existence so it may be a custom-processor plugin or such
>> for this purpose.
>
>
> The issue is Mailman core would have to keep track of the message-ids
> and thread number of all prior posts to know whether the current post
> is a reply to some other post or not.
>
> You would need a new database table or some other mechanism to keep
> track of this and then you may need to keep everything forever because
> you can't know that there won't be a future post in reply to some very
> old post.
>
I think this is doable in our (read: Employer) use case, but without
needing to modify Mailman Core much beyond a custom plugin and some
fussing around.
This is a side effect of a custom implementation of "Tagging" data by
thread ID in a separate data / intel tagging system that reads from
received emails in a custom intel processing mailbox. That has zero care
as to how Mailman or Hyperkitty index items, and actually is pretty
trivially implemented with `PREFIX` format being [ListName-NNNNNNN]:
1. If subject does not match `PREFIX` format:
* Get next thread number from DB (In postgres, this is a serial
matched to {list_id}_thread we call with nextval())
* Add subject prefix as [ListName-{ZeroPaddedThreadNumFromDB}]
2. If subject matches `PREFIX` form:
* Do nothing
As for how HyperKitty handles this, it replies entirely on RFC 5322
fields (see section 3.6.4 in that RFC) for identifying reply to, etc. to
identify replies to things, which in turn it seems is fully capable of
handling that. We simply need the message to be sent *with* a thread ID
that members can hit reply to and keep the prefix in the subject line.
We don't care how that's done in the Hyperkitty side of things, we only
care about it being sent in the subject line.
I noticed that Mailman3 has the capacity for external / custom plugins,
and with some work I believe I can achieve this with a customized
pipeline with a custom handler of `thread-prefix` instead of
`subject-prefix`, otherwise calling the other handlers done by the
traditional system, and just handle prefix differently in the
thread-prefix handler in the custom pipeline. I'm following this
attempt currently, but will keep it internal to employer. It'll also be
kept internal to our use-case because it isn't easily exportable to
other Mailman3 implementations.
But yes, you're right it needs additional DB table to map list_id <-->
thread_id and then would need some kind of "Subject prefix uses thread
IDs instead of Post IDs config option", or only handle based on a custom
pipeline.
I"m going to deep dive into this on my end and see if I can come up with
a solution that relies direct on the DB calls. Which hopefully should
be safe to do, but we'll see in testing.
Thomas
1 year, 8 months

[MM3-users] Re: upgrading in FreeBSD 13.1-p7: problem with aiosmtpd and lmtp runner
by Guillermo Hernandez (Oldno7)
El 3/4/23 a las 1:25, Mark Sapiro escribió:
> On 4/2/23 03:57, Guillermo Hernandez (Oldno7) via Mailman-users wrote:
>>
>> I'm NOT blaming any of the parts involved... Sure, most probably is
>> my fault. But the last upgrade shows that the process that fail is
>> involved with mailman upgrade. The last server was working smoothly
>> and it has higher traffic than the first I tried. It cannot be that I
>> missed that something was not working for weeks (since the last
>> upgrade of the OS)
>
> It depends on what you did. Mailman's lmtp runner would only encounter
> this issue at startup, so unless you restarted Mailman or rebooted the
> server, lmtp runner would have continued without issue even if there
> was an underlying OS problem.
I thought I said it: I reboot this server everyday at 06:40 CEST time.
That's why I'm sure it's not an undetected problem for weeks. The lists
in this last upgraded server are with daily traffic. I'm suscribed to all.
>
> Also, I don't think the problem is with Mailman per se. The underlying
> issue is in the Python library socket module. Try the following in a
> Python 3 shell
> ```
> $ python3
> Python 3.9.16 (main, Dec 11 2022, 12:49:23)
> [GCC 9.4.0] on linux
> Type "help", "copyright", "credits" or "license" for more information.
> >>> from socket import AF_INET6, SOCK_STREAM, socket as makesock
> >>> sock = makesock(AF_INET6, SOCK_STREAM)
> >>> sock.bind(("::1", 0))
> >>> sock.close()
> ```
> This is essentially what aiosmtpd does and I expect that `sock =
> makesock(AF_INET6, SOCK_STREAM)` will throw the `OSError: [Errno 43]
> Protocol not supported` exception.
>
And you are right (ther is more down of this):
Python 3.9.16 (main, Dec 15 2022, 09:41:07)
[Clang 13.0.0 (git@github.com:llvm/llvm-project.git
llvmorg-13.0.0-0-gd7b669b3a on freebsd13
Type "help", "copyright", "credits" or "license" for more information.
>>> from socket import AF_INET6, SOCK_STREAM, socket as makesock
>>> sock = makesock(AF_INET6, SOCK_STREAM)
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/usr/local/lib/python3.9/socket.py", line 232, in __init__
_socket.socket.__init__(self, family, type, proto, fileno)
OSError: [Errno 43] Protocol not supported
Buuuuuut, if I do the same in the "father" server:
Python 3.9.16 (main, Dec 15 2022, 09:41:07)
[Clang 13.0.0 (git@github.com:llvm/llvm-project.git
llvmorg-13.0.0-0-gd7b669b3a on freebsd13
Type "help", "copyright", "credits" or "license" for more information.
>>> from socket import AF_INET6, SOCK_STREAM, socket as makesock
>>> sock = makesock(AF_INET6, SOCK_STREAM)
>>> sock.bind(("::1", 0))
>>> sock.close()
File "<stdin>", line 1
sock.close()
IndentationError: unexpected indent
>>> sock.close()
>>>
The server can open a socket without problem. As I though previously it
has to be something with the jailed envviroment. Your test had probe me
right (and wrong in my jail tests). It's very valuable. I know now where
I can dig more.
Thanks a lot
--
___________________________________________
Mailman's content filtering has removed the
following MIME parts from this message.
Content-Type: image/png
Name: firma-GHP-emails.png
Replaced multipart/alternative part with first alternative.
2 years, 3 months

[MM3-users] compress failed (was Re: Solved Re: after last upgrade I've got a CSRF failed verification)
by Guillermo Hernandez (Oldno7)
El 28/10/22 a las 9:18, Guillermo Hernandez (Oldno7) via Mailman-users
escribió:
>
> El 27/10/22 a las 21:39, Mark Sapiro escribió:
>>> After that the compress part showed errors... but the postorius web
>>> maintenance was working well except for the CSRF error verification.
>>> I will trace the compress errors and will try to find the problem
>>> later.
>>
>>
>> Do you have `COMPRESS_ENABLED = True` in your settings? If that's not
>> the issue, it may be in the settings for COMPRESS_PRECOMPILERS
>
> While I'm tracing the problem out, this is the configuration I had
> working and the error it shows after upgrade:
>
> <------- snip of settings.py>
>
> #
> COMPRESS_PRECOMPILERS = (
> ('text/less', 'lessc {infile} {outfile}'),
> ('text/x-scss', 'sassc -t compressed {infile} {outfile}'),
> ('text/x-sass', 'sassc -t compressed {infile} {outfile}'),
> )
> # On a production setup, setting COMPRESS_OFFLINE to True will bring a
> # significant performance improvement, as CSS files will not need to be
> # recompiled on each requests. It means running an additional "compress"
> # management command after each code upgrade.
> #
> http://django-compressor.readthedocs.io/en/latest/usage/#offline-compression
> #### activo compresion 18/12/20
> COMPRESS_OFFLINE = True
> ###COMPRESS_OFFLINE = False
> <---------- end snip>
>
> And below is the error it shows:
>
> /usr/local/mailman3 # su -m mailman3 -c "python3 manage.py compress"
> Traceback (most recent call last):
> File "/usr/local/mailman3/manage.py", line 10, in <module>
> execute_from_command_line(sys.argv)
> File
> "/usr/local/lib/python3.9/site-packages/django/core/management/__init__.py",
> line 446, in execute_from_command_line
> utility.execute()
> File
> "/usr/local/lib/python3.9/site-packages/django/core/management/__init__.py",
> line 440, in execute
> self.fetch_command(subcommand).run_from_argv(self.argv)
> File
> "/usr/local/lib/python3.9/site-packages/django/core/management/__init__.py",
> line 279, in fetch_command
> klass = load_command_class(app_name, subcommand)
> File
> "/usr/local/lib/python3.9/site-packages/django/core/management/__init__.py",
> line 49, in load_command_class
> return module.Command()
> File
> "/usr/local/lib/python3.9/site-packages/django/core/management/base.py",
> line 274, in __init__
> raise TypeError("requires_system_checks must be a list or tuple.")
> TypeError: requires_system_checks must be a list or tuple.
>
>
After searching around, I've got a hint of what can be happening. It
seems a variable has changed in Django 4.1 its nature from boolean to a
tuple
https://github.com/painless-software/django-probes/issues/24
I've upgraded another server with mailman3 lists, with the same config
listed above, and it shows the same error in the "compress" part. I'm
not sure where to set the requires_system_checks variable as in one of
the comments of the link, and as it doesn't seems to break anything
more, I will wait for more info before trying to avoid it. I'm sure it
will have some repercusion on the performance, but I'll have to live
with it.
Thanks again for your supporting advices.
>
>
>
>
>
--
___________________________________________
Mailman's content filtering has removed the
following MIME parts from this message.
Content-Type: image/png
Name: firma-GHP-emails.png
Replaced multipart/alternative part with first alternative.
2 years, 8 months

[MM3-users] Re: Splitting hosts: mta&core vs postorius
by Ruth Ivimey-Cook
Thanks Mark,
On 20/06/2020 03:53, Mark Sapiro wrote:
On 6/19/20 4:34 PM, Ruth Ivimey-Cook wrote:
I'm trying to set up mailman3 on two hosts, one of which runs core +
exim, the other runs postorius (&possibly hyperkitty).
I have I think got core set up correctly, and postorius is sort of
usable, but anything in the web ui that talks to core ends up with a
white screen.
I think what is happening is a postorius URL ends up with the core (or
perhaps no) hostname, and as there's nothing there to answer it fails.
What are your Django settings for MAILMAN_REST_API_URL,
MAILMAN_REST_API_USER and MAILMAN_REST_API_PASS and do these agree with
the [webservice] settings for hostname, port, use_https, admin_user and
admin_pass in mailman.cfg in core and is the port open to the outside on
the core machine?
greyarea-post is the mailman-core and exim server.
greyarea-web1 is the postorius and hyperkitty server.
On greyarea-web1, in django-settings.py,
MAILMAN_REST_API_URL = '[1]http://greyarea-post:8870'
MAILMAN_REST_API_USER = 'restadmin'
MAILMAN_REST_API_PASS = XXXX
and both the above-named hosts are also included in ALLOWED_HOSTS along
with localhost.
On greyarea-post, in mailman.cfg:
[webservice]
admin_pass: XXXXX
admin_user: restadmin
api_version: 3.1
hostname: 0.0.0.0
port: 8870
use_https: no
The password and username are as on web1.
Do you see REST requests from the Postorius machine in core's
mailman.log and access.log?
Yes, there are lots of requests of the form:
[07/Jun/2020:15:00:01 +0000] "GET /3.1/lists?count=10&page=1
HTTP/1.1" 200 470 "-" "GNU Mailman REST client v3.3.1"
I made a new list using the core CLI, and as a result of navigating
directly to the list archive page I get to see:
[06/Jun/2020:23:00:02 +0000] "GET /3.1/lists/chbcdaily(a)ch-bc.org.uk
HTTP/1.1" 200 365 "-" "GNU Mailman REST client v3.3.1"
... but in neither case do I get a complete screen on the browser or
'follow-up' requests.
I don't have a file access.log on the greyarea-post.
On the greyarea-web1 I have mailmansuite.log with the last few lines:
File
"/opt/mailman3/lib/python3.6/site-packages/mailmanclient/restbase/ba
se.py", line 74, in rest_data
response, content = self._connection.call(self._url)
File
"/opt/mailman3/lib/python3.6/site-packages/mailmanclient/restbase/co
nnection.py", line 124, in call
'Could not connect to Mailman API: ', repr(e))
mailmanclient.restbase.connection.MailmanConnectionError: ('Could
not connect to Mailman API: ',
'ConnectionError(MaxRetryError("HTTPConnectionPool(host=\'0.0.0.0\',
port=8870): Max retries exceeded with url: /3.1/domains/ch-bc.org.uk
(Caused by NewConnectionError(\'<urllib3.connection.HTTPConnection
object at 0x7f5416db8518>: Failed to establish a new connection:
[Errno 111] Connection refused\',))",),)')
ERROR 2020-06-03 01:02:06,115 29002 django.request Service
Unavailable: /postorius/lists/
the uwsgi-error_*.log contains many lines of the form:
api: url is
[2]http://greyarea-post.cam.ivimey.org:8870/3.1/lists?count=10&page=
1
api: url is
[3]http://greyarea-post.cam.ivimey.org:8870/3.1/lists?count=10&page=
1
My reason for thinking, in my original post, that the wrong host
address is being used is that the ConnectionError above contains
0.0.0.0 in its url for /3.1/domains/... but 0.0.0.0 is only present as
the listen address on the core web service and does not appear in the
config for postorius.
I hope this helps,
Ruth
--
--
Software Manager & Engineer
Tel: 01223 414180
Blog: [4]http://www.ivimey.org/blog
LinkedIn: [5]http://uk.linkedin.com/in/ruthivimeycook/
References
1. http://greyarea-post:8870/
2. http://greyarea-post.cam.ivimey.org:8870/3.1/lists?count=10&page=1
3. http://greyarea-post.cam.ivimey.org:8870/3.1/lists?count=10&page=1
4. http://www.ivimey.org/blog
5. http://uk.linkedin.com/in/ruthivimeycook/
5 years

[MM3-users] Re: Sending a message to a subscription applicant when a subscription request is made
by Allan Hansen
Thank you, Mark. That makes sense.
And, as you suggested, this will not work for me, because a lot of people log in and then apply to more lists. I can't exhort them to get the accounts set up and do their subscription maintenance while logged in, and they tell them that if they want to sign up for another list they have to log out first. __
I do need to find another way. I suggested these options:
a. That we change the lines in the Python program in our installation that send 'list:admin:action:subscribe' to the list admins to instead send the template to the applying subscriber.
b. That we change the lines in the Python program in our installation that send 'list:user:action:subscribe' to the subscriber with an unverified address to always do this, even when the incoming address has already been verified.
c. That the current 'list:user:action:subscribe' be changed in published Mailman 3 source to 'list:user:action:confirm' and a new template ''list:user:action:subscribe' be set up to be sent when any subscribe request is made. This is more work, of course, so not likely a good thing to hack locally. It could be useful to other users.
Of course, (a.) and (b.) are preferred in the short term, as I'd like to get our procedure simplified.
Any idea which file to change for either, and some suggestion as to what to change?
Yours,
Allan
On 3/28/23, 10:18, "Mark Sapiro" <mark(a)msapiro.net <mailto:mark@msapiro.net>> wrote:
On 3/28/23 09:19, Allan Hansen wrote:
> Mark,
>
> I tried doing this.
> I unsubscribed myself from a list, set the policy as you suggest and re-applied.
> I got no confirmation messages but as moderator I got the moderate message.
How did you reapply? with the subscribe policy confirm then moderate a
new subscriber should get the list:user:action:subscribe message and
have to confirm before the request waits moderation? However, see below.
> I then tried a bogus email and saw that a message was sent to that and no moderator message to me.
> Would the server skip the verification message because I'm a moderator/admin?
It's not because you are an admin. It's because you were logged in when
you subscribed from the list's info page. You will need to confirm if
you subscribe anonymously without logging in or subscribe via email, but
if you are logged in to Postorius when you request subscription, that is
sufficient confirmation that the request really comes from you, so you
don't get an email confirmation.
So, depending on your circumstances, this may or may not work for you.
--
Mark Sapiro <mark(a)msapiro.net <mailto:mark@msapiro.net>> The highway is for gamblers,
San Francisco Bay Area, California better use your sense - B. Dylan
_______________________________________________
Mailman-users mailing list -- mailman-users(a)mailman3.org <mailto:mailman-users@mailman3.org>
To unsubscribe send an email to mailman-users-leave(a)mailman3.org <mailto:mailman-users-leave@mailman3.org>
https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/ <https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/>
Archived at: https://lists.mailman3.org/archives/list/mailman-users@mailman3.org <mailto:mailman-users@mailman3.org>/message/D4WXXVOHXTDLRDGXV66GV4BAMWBRYEPF/
This message sent to hansen(a)rc.org <mailto:hansen@rc.org>
2 years, 3 months

[MM3-users] mailman.cfg (use_https: yes) fails
by Wolfgang Bock
Hello,
I configuered 3 domains in postorius
https://[mydomain]/mailman3/postorius/domains/ ... also shown here:
https://[mydomain]/mailman3/admin/sites/site/ (django)
I installed mailman3 with debian command apt-get install mailman3-full.
The package mailman3-full is described as follows:
Paket: mailman3-full (3.2.1-1) (for debian-buster, W.B.)
...
Betreuer:
* Debian Mailman Team
<mailto:pkg-mailman-hackers@lists.alioth.debian.org> (QS-Seite
<https://qa.debian.org/developer.php?login=pkg-mailman-hackers%40lists.aliot…>,
E-Mail-Archiv
<https://lists.alioth.debian.org/pipermail/pkg-mailman-hackers/>)
* Pierre-Elliott Bécue <mailto:peb@debian.org> (QS-Seite
<https://qa.debian.org/developer.php?login=peb%40debian.org>)
* Jonas Meurer <mailto:jonas@freesources.org> (QS-Seite
<https://qa.debian.org/developer.php?login=jonas%40freesources.org>)
Full Mailman3 mailing list management suite (metapackage)
This is GNU Mailman, a mailing list management system. This metapackage
depends on all components of the full Mailman3 suite:
* mailman3: The core Mailman3 delivery engine
* mailman3-web: Django project integrating Mailman3 postorius and
hyperkitty
* python3-mailman-hyperkitty: Mailman3 server plugin for Hyperkitty
archiver
.....
That's the output of # mailman info
GNU Mailman 3.2.1 (La Villa Strangiato)
Python 3.7.3 (default, Apr 3 2019, 05:39:12)
[GCC 8.3.0]
config file: /etc/mailman3/mailman.cfg
db url:
mysql+pymysql://[-secret-][mydomain]/mailman3?charset=utf8&use_unicode=1
devmode: DISABLED
REST root url: http://localhost:8001/3.1/
REST credentials: restadmin:[-secret-]
I dont know what version of mailman client is included in the package.
Should I wait until an update includes a higher Version of the
mailman-client?
In this context I faced a strange behavior:
In the database mailman3web in table django_site are listed several
domains, either in the django-domain-management site
https://[mydomain]/mailman3/admin/sites/site/
id domain name
1 example.com Example.com
2 [mydomain-1] [mydomain_name_1]
3 [mydomain-2] [mydomain_name_2]
4 [mydomain-3] [mydomain_name_3]
In case I delete line 1 with the id 1, in the database or in the
django-web-site, postorius fails to work. After re-inserting this line,
postorius works again.
Regards
Wolfgang
Am 16.11.2019 um 01:02 schrieb Mark Sapiro:
> On 11/15/19 3:45 AM, Wolfgang Bock via Mailman-users wrote:
>> That doesn't solve the problem. I changed that in mailman-web.py
>> (MAILMAN_REST_API_URL = https://localhost:8001) and after that in
>> mailman.cfg (use_https: yes). But got the same errormessage on postorius
>> website.
>
> You posted this log excerpt:
>
> Nov 14 23:20:41 2019 (28590) 127.0.0.1 - - "GET
> /3.0/lists?advertised=true&count=0&page=1 HTTP/1.1" 200 90
> Nov 14 23:20:41 2019 (28590) 127.0.0.1 - - "GET
> /3.0/lists?advertised=true&count=10&page=1 HTTP/1.1" 200 606
> Nov 14 23:20:41 2019 (28590) 127.0.0.1 - - "GET /3.1/domains HTTP/1.1"
> 200 1438
> Nov 14 23:20:41 2019 (28590) 127.0.0.1 - - code 400, message Bad
> HTTP/0.9 request type
>
>
> The first 3 GETs are a normal sequence of GETs from Postorius when you
> go to the Mailing Lists view. That should be followed by a GET like "GET
> /3.1/domains/domain.tld HTTP/1.1" where domain.tld is a configured
> domain. Do you have any domains configured?/0.9'?
>
> I'm not sure what the issue is. You have an older version of
> mailmanclient < 3.2.3a1 which uses httplib2 rather than requests.
> https://pypi.org/project/httplib2/ says:
>
> HTTP and HTTPS
> HTTPS support is only available if the socket module was compiled
> with SSL support.
>
> but I don't think this can be the issue because the first 3 GETs work.
>
> You might try upgrading mailmanclient to 3.3.0. I don't know if that
> will help, but it may.
>
5 years, 7 months

[MM3-users] Re: integrating mm3 with postfix / lmtp
by Thor Atle Rustad
There is a way around it!
I have had two issues with the the maxking docker image. One is that the
regexp is not working properly. I reported that, and it has been fixed in
newer code. My other problem is that the docker image creates a user,
mailman, that receives uid 103. Well, uid 103 on my system is already taken
by systemd-bus-proxy (grep 103 /etc/passwd returns
"systemd-bus-proxy:x:103:105:systemd Bus
Proxy,,,:/run/systemd:/bin/false").
My solution includes downloading the corrected postfix.py, and replacing
the Dockerfile. I put the postfix.py in <docker-mailman>/core/assets/.
My Dockerfile:
FROM maxking/mailman-core
RUN grep mailman /etc/passwd && grep mailman /etc/group \
&& deluser mailman \
&& addgroup -S -g900 mailman \
&& adduser -S -u900 mailman mailman \
&& grep mailman /etc/passwd && grep mailman /etc/group
COPY assets/postfix.py
/usr/local/lib/python3.6/site-packages/mailman/mta/postfix.py
I then run docker build (with -t parameter, you must look up that
yourself). I use a different name for my images, so I end up with (note,
there are two tags per image):
root@mailer:/home/mailman/docker/docker-mailman_mods/core# docker images
REPOSITORY TAG IMAGE ID CREATED
SIZE
local/mailman_core_900 20171110_2 9649e84767e1 2 days
ago 176MB
local/mailman_core_900 latest 9649e84767e1 2 days
ago 176MB
local/mailman_web_900 20171110_2 07a9b3d7ddd6 2 days
ago 247MB
local/mailman_web_900 latest 07a9b3d7ddd6 2 days
ago 247MB
I do the same with the web image, as I need to change the user there, too.
Then, in docker-compose.yaml, I change the line(s) referring to the image
name(s):
services:
mailman-core:
image: local/mailman_core_900
container_name: mailman-core
hostname: mailman-core
mailman-web:
image: local/mailman_web_900
container_name: mailman-web
hostname: mailman-web
I don't know if this is a good solution, but at least it fixes some serious
issues with the 3.1's postfix integration that wouldn't otherwise be fixed
until the 3.2 release. The bottom line is that it works for me, but it adds
an additional layer of complication.
2017-11-03 19:40 GMT+01:00 Abhilash Raj <maxking(a)asynchronous.in>:
> On Fri, Nov 3, 2017, at 08:29 AM, Fabian A. Santiago wrote:
> > October 26, 2017 11:07 PM, "Mark Sapiro" <mark(a)msapiro.net> wrote:
> >
> > > On October 26, 2017 7:30:35 PM PDT, "Fabian A. Santiago" <
> fsantiago(a)garbage-juice.com> wrote:
> > >
> > >> That was it. Perfect. I manually modified my regexp map and it works
> > >> now. Excellent and Thank you. You're the man. Does mm3 ever refresh
> > >> those maps or only as I add new domains / lists?
> > >
> > > Only when you make changes to domains or lists.
> > >
> > > --
> > > Mark Sapiro <mark(a)msapiro.net>
> > > Sent from my Not_an_iThing with standards compliant, open source
> software.
> >
> > Mark,
> >
> > I've noticed that even simply restarting the mm3 components those alias
> > maps get rewritten and the problem returns until I can manually edit it.
>
> Yeah, that is true. Transport maps are re-generated everytime the
> container restarts.
>
> I don't think think there is any way around this right now :(
>
>
> --
> Abhilash Raj
> maxking(a)asynchronous.in
> _______________________________________________
> Mailman-users mailing list
> mailman-users(a)mailman3.org
> https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/
>
7 years, 7 months

[MM3-users] Re: using SSH/TLS with external MTA
by Odhiambo Washington
On Sun, Jul 28, 2024 at 8:35 PM Mark Sapiro <mark(a)msapiro.net> wrote:
> On 7/28/24 09:54, Roland Giesler via Mailman-users wrote:
> >
> > These settings from the Django docs look like the ones in mailman.cfg.
> > Do I have to set them somewhere else too?
>
>
> Yes. The settings in mailman.cfg only affect mail from Mailman. For mail
> from Django, you have to set things like
>
> EMAIL_HOST = 'box2.gtahardware.co.za'
> EMAIL_PORT = 465
> EMAIL_HOST_USER = 'roland(a)giesler.za.net'
> EMAIL_HOST_PASSWORD = '...'
>
> and possibly others as desired, See the links to the Django docs for these.
>
>
> > * |use_tls|:|EMAIL_USE_TLS|
> >
> > <
> https://docs.djangoproject.com/en/5.0/ref/settings/#std-setting-EMAIL_USE_T…
> >
> > * |use_ssl|:|EMAIL_USE_SSL|
> >
> > <
> https://docs.djangoproject.com/en/5.0/ref/settings/#std-setting-EMAIL_USE_S…
> >
> > * |timeout|:|EMAIL_TIMEOUT|
> >
> > <
> https://docs.djangoproject.com/en/5.0/ref/settings/#std-setting-EMAIL_TIMEO…
> >
> > * |ssl_keyfile|:|EMAIL_SSL_KEYFILE|
> >
> > <
> https://docs.djangoproject.com/en/5.0/ref/settings/#std-setting-EMAIL_SSL_K…
> >
> > * |ssl_certfile|:|EMAIL_SSL_CERTFILE|
> >
> > <
> https://docs.djangoproject.com/en/5.0/ref/settings/#std-setting-EMAIL_SSL_C…
> >
>
> This all goes in your Django settings which from other posts I gather is
> /etc/mailman3/mailman3-web.py. I'm guessing you are using the Debian
> packages and that's where the package puts the Django settings.
>
I am following this thread out of curiosity.
So I added the same lines to my /opt/mailman3/settings.py - on a virtualenv
install of the latest MM3 code.It's my test VM.
After adding the lines and restarting mailmanweb, I then entered the
virtualenv and did 'mailman-web createsuperuser' which completed
successfully, but NO MAIL!
As matter of fact, there isn't even anything in the logs of the MTA running
at w.kictanet.or.ke.
```
root@ubuntu24:/home/wash# su mailman
(venv) mailman@ubuntu24:~$ tail -n 5 /etc/mailman3/settings.py
EMAIL_HOST = 'gw.kictanet.or.ke'
EMAIL_PORT = 587
EMAIL_HOST_USER = 'mailman(a)gw.kictanet.or.ke'
EMAIL_HOST_PASSWORD = 'XXXXXXYYYYYYYZZZZ'
(venv) mailman@ubuntu24:~$ mailman-web createsuperuser
Username (leave blank to use 'mailman'): mm3admin1
Email address: odhiambo(a)outlook.com
Password:
Password (again):
Superuser created successfully.
(venv) mailman@ubuntu24:~$ tail -n 5 /opt/mailman/web/logs/mailmanweb.log
[Nothing in that file]
(venv) mailman@ubuntu24:~$ tail -n 10 /opt/mailman/mm/var/logs/mailman.log
[2024-07-29 13:41:22 +0300] [301491] [INFO] Starting gunicorn 22.0.0
[2024-07-29 13:41:22 +0300] [301491] [INFO] Listening at:
http://127.0.0.1:8001 (301491)
[2024-07-29 13:41:22 +0300] [301491] [INFO] Using worker: sync
[2024-07-29 13:41:22 +0300] [301537] [INFO] Booting worker with pid: 301537
[2024-07-29 13:41:22 +0300] [301538] [INFO] Booting worker with pid: 301538
Jul 29 13:41:23 2024 (301485) bounces runner started.
[29/Jul/2024:13:45:52 +0300] "GET /3.1/domains HTTP/1.1" 200 333 "-" "GNU
Mailman REST client v3.3.5"
[29/Jul/2024:13:45:52 +0300] "GET /3.1/domains/lists.wash.lan HTTP/1.1" 200
228 "-" "GNU Mailman REST client v3.3.5"
[29/Jul/2024:13:45:52 +0300] "GET /3.1/users/odhiambo(a)gmail.com HTTP/1.1"
200 395 "-" "GNU Mailman REST client v3.3.5"
[29/Jul/2024:13:45:52 +0300] "POST /3.1/lists/find HTTP/1.1" 200 503 "-"
"GNU Mailman REST client v3.3.5"
--
Best regards,
Odhiambo WASHINGTON,
Nairobi,KE
+254 7 3200 0004/+254 7 2274 3223
In an Internet failure case, the #1 suspect is a constant: DNS.
"Oh, the cruft.", egrep -v '^$|^.*#' ¯\_(ツ)_/¯ :-)
[How to ask smart questions:
http://www.catb.org/~esr/faqs/smart-questions.html]
11 months

[MM3-users] Re: nginx configuration on a multitasking server
by David Newman
On 12/10/21 12:57 PM, Mark Sapiro wrote:
> On 12/10/21 10:22 AM, David Newman wrote:
>>
>> 1. At least on my system, the proxy_pass statement will only run
>> without errors if I change this to a fully formed URL, e.g.,
>> 'proxy_pass http://127.0.0.1:8000'. Is this a typo in the docs?
>
>
> I changed it at
> https://docs.mailman3.org/en/latest/install/virtualenv.html#nginx-configura…
> but I wonder if we shouldn't be using `uwsgi_pass` instead of proxy_pass.
>
> See https://nginx.org/en/docs/http/ngx_http_uwsgi_module.html#uwsgi_pass
>
> Are you using uwsgi or some other wsgi server.
uwsgi, per the venv and PDF docs. Thanks for the fix.
Regarding the uwsgi_pass docs, would 'uwsgi_pass_header' directives
replace the 'proxy_set_header' ones in the venv doc?
Looking at the uwsgi doc, it seems they might do different things.
>> 2. What document root(s) and alias(es) to use for Postorius and
>> Hyperkitty and the Django admin on a server that also runs other
>> services (e.g., Postfix for non-list mail and Roundcubemail)?
>
>
> If you can separate Mailman from other services by subdomain
Alas, I can do that for all but one of the subdomains I have in production.
For the past 15 or so years, users of that subdomain have used
mail.domain.tld for MM2, roundcubemail, and an admin web UI that manages
regular mail.
The "/" has gone to roundcubemail, and users to go other directories for
the other services. For example, MM2 users currently go to /mailman.
, you can
> configure them separately and for Mailman, root is irrelevant as
> everything is proxied or aliased in a location directive. For example,
> Mailman on the server that supports this list uses the
> lists.mailman3.org domain and we have (excerpted)
> ```
> server {
> listen 443 default_server;
> root /usr/share/nginx/html;
> index index.html index.htm;
> # root and index are probably irrelevant as we never go there
> server_name lists.mailman3.org;
> ssl on;
> #ssl stuff
> location / {
> proxy_pass http://127.0.0.1:8000/;
> # other proxy stuff
In this example, / goes to MM3.
The assumption here and in the MM3 docs is that we're standing up a
dedicated server where MM3 pages should be served as the default. That's
a totally valid design decision, and one could argue it's superior to
running a bunch of other services on one machine.
It's not the situation I have to deal with, though. Short of changing a
long-standing URL, what I'm looking to do is have "/" continue to
default to roundcubemail, and have users type in longer URLs for MM3 and
other services.
You're right that the root and index directives above are irrelevant
since / goes to MM3 via proxy.
What I'm asking is what root(s) and location(s) to use with nginx where
MM3 isn't the default.
Thanks again!
dn
> }
> location /static/ {
> alias /var/spool/mailman-web/static/;
> }
> location /robots.txt {
> alias /usr/share/nginx/html/robots.txt;
> }
> location /favicon.ico {
> alias /var/www/listorg/images/favicon.ico;
> }
> }
> ```
> And for the other stuff we have
> ```
> server {
> listen 443;
> server_name .list.org mirror.list.org mirror.mailman3.org;
> root /var/www/listorg;
> ssl on;
> # ssl stuff
> }
>
>
3 years, 6 months

[MM3-users] Re: Mailman sends Welcome emails, but does not send [List] postings emails
by Nelson Strother
Neither .../logs/mailman.log nor /var/log/syslog contain any recording
of "Master detected ..." nor process exits other than at the time of
`mailman stop` commands. Watching during these transitions with `vmstat`
shows a decrease in free pages and an increase in swapping, but no
definitive hint of the OOM reaper running.
I did not intend to imply that `mailman start` (predictably) consumes
more time than `mailman restart`. Both are lengthy and variable; I think
one cause for `mailman stop` consuming more time than usual is when
mailman receives a message as it is trying to stop, which is understandable.
Interestingly if I use `systemctl start mailman` thus far the results are:
- the wall clock duration is shorter than when `mailman start` is issued
from the command line, and
-- either that all of the runners remain present once they are started,
-- or I can see in syslog a traceback from each missing runner process
starting from .../mailman/.local/bin/runner and ending with
"flufl.lock._lockfile.NotLockedError: Already unlocked".
I do not yet understand how to make use of these clues, but at least one
can see an epitaph from each deceased process.
On 6/6/23 14:47, Mark Sapiro wrote:
> On 6/6/23 07:58, Nelson Strother wrote:
>>
>> No errors are being recorded in the mailman log files. This is GNU
>> Mailman 3.3.8 via `pip install mailman` on Debian 5.10.179-1
>> (2023-05-12) running on a shared system where VMware gives this
>> server enough cycles that `mailman start` and `mailman stop` each
>> consume from 20 minutes to an hour of wall clock time, so I do not
>> issue those commands recreationally, attempting to keep the system
>> available for users. What should I do to help understand the cause
>> for these failures?
>
>
> If a runner has died, its death and a reason should be logged in
> Mailman's var/logs/mailman.log with a message similar to
>
> Master detected subprocess exit (pid: 8617, why: SIGNAL 15, class: in,
> slice: 1/1)
>
> This may not be the case if the runner is killed by the OS for an out
> of memory or similar reason. For this, look in syslog.
>
> `mailman stop` can take a long time because it is waiting for a runner
> to stop. See https://gitlab.com/mailman/mailman/-/issues/255 but that
> issue was fixed long ago. I don't understand why `mailman start` would
> take more time than `mailman restart`. In fact, `mailman restart`
> effectively does `stop` and `start`, but only for those runners which
> are running.
>
> Since you seem to frequently have missing runners, I suspect something
> like an OOM condition is causing the OS to kill them. Although, I
> wonder if you are correctly interpreting the logs. While the absence
> of the `retry`, `task`, `nntp` and `archive` runners might not be
> noticed except for messages not being archived, if either the `in` or
> `pipeline` runner is not running, no list posts will be processed.
>
>
>> Would not it be helpful for this limitation of restart to be included
>> in:
>> mailman restart --help
>> with a suggestion to use `mailman stop` and `mailman start` instead?
>
>
> I have just filed https://gitlab.com/mailman/mailman/-/issues/1082 for
> this.
>
2 years

[MM3-users] Re: File "/usr/lib/python2.7/httplib.py", line 1148, in getresponse raise ResponseNotReady()
by Alex Schuilenburg
On Fri, 2020-10-02 at 20:28 -0700, Mark Sapiro wrote:
> [...]Part of what's going on is some MM 2.1 archives has email
> addressesobfuscated by replacing `@` with ` at ` so the import
> process reversesthis and changes the From: toheader is```From:
> Firstname Surname@example-UK <user(a)example.com>```which now contains
> two email addresses albeit not separated by a commaand picks the
> first. The message then gets properly archived withsender `Firstname
> Surname@example-UK` which is a syntactically validemail address and
> doesn't cause the ResponseNotReady() exception insync_mailman so I
> don't see that issue.
I saw the message archived also, but in the sync_mailman I did pick up
something.
I'm a bit old school so my first goto is normally a strace. From that I
saw the sync connect to the rest qrunner, querying each email address
for their mailman id. However, when it came to querying the dodgy
email, it did not get that far. The connection was made and closed.
Initially I thought the rest closed its connection before the sync
could even get it's query out (i.e. GET /3.0/users/Firstname
Surname@example-UK) but an strace on the rest and the sync shows the
connection made and closed immediately afterwards at both ends. Twice
in fact (IPv4 and IPv6). Previous calls were as you would expected
with the GET and HTTP/1.0 response.
The traceback ResponseNotReady() exception within
the client.get_user(self.address) call of Sender.set_mailman_id in
hyperkitty/models/sender.py only makes sense if sync was attempting to
talk on a closed socket.
So I didn't get it - I still dont. Why did the sync not get as for as
the rest "GET /3.0/users/Firstname Surname@example-UK" and "HTTP/1.0
404 Not Found" exchange, as it had with the previous (valid) email?
Why was the rest socket closed without a query made? My only thought
last night was that the rest connection was established by the sync,
when then decided to close the connection because the email was
invalid, but it continued attempting to get the mailman_id hence the
exception.
Anyway, you then stepped up with your suggestion, I added the correct
email to hyperkitty_sender, updated the faulty email record in
hyperkitty_email to point to the correct hyperkitty_sender record and
deleted the dodgy hyperkitty_sender record, and the sync passed. All
good for me anyway.
> The difference is either the fact that my test runs with the HEAD of
> theGitLab branch which may not have the issue or the difference
> between thereal From: header and the sanitized one is significant.
If the sync works for you in the trunk now, there seems little point
figuring out why this does not work in the current debian package.
Hopefully there will be an update by debain soon, and for now I can
carry on my import and fix the issue if it happens again.
However, it would be interesting to know what ends up in your archive?
I suspect it will have the dodgy "Firstname Surname@example-
UK" address as the sender. If that is the case then certainly as you
mention in
https://gitlab.com/mailman/hyperkitty/-/issues/320#note_423030205,
HyperKitty's wrapper should be smarter and call
email.utils.parseaddr() first and only try replacing at if the returned
address doesn't contain @. Otherwise you end up with a bad import and
dodgy email in your archives.
Thanks
-- Alex
4 years, 8 months

[MM3-users] [SOLVED] Re: Re: multiple sites on a mailman3 server question
by William Oliver
On Wed, 2021-12-29 at 09:21 -0800, Mark Sapiro wrote:
> On 12/29/21 8:48 AM, William Oliver wrote:
> >
>
>
[snip]
> If you are following
> https://docs.mailman3.org/en/latest/install/virtualenv.html you have
> ```
> location / {
> proxy_pass http://127.0.0.1:8000;
> proxy_set_header Host $host;
> proxy_set_header X-Forwarded-For $remote_addr;
>
> }
> ```
> in your nginx config and everything goes to uwsgi. What you want is to
> put those proxy directives in only the mailman locations as at
> https://lists.mailman3.org/archives/list/mailman-users@mailman3.org/message…
>
> and then configure your document root so other locations are served
> from
> there.
>
The problem was more stupid than one might imagine. My browser was
caching so no matter what changes I made, it loaded
domain/mailman/lists because that was what was cached. When I tinkered
with things, I only changed whether or not mailman was loaded after
that. I changed machines and used a different browser, and it started
working fine. And it worked fine on my regular box once I cleared my
browser's cache.
It turns out that nginx works like it's supposed to work. Go figure.
So, just to make things clear. Here was my goal:
www.domain.com <-- go to welcome page
lists.domain.com <-- go to mailman
later, I'll install roundcube for mail.domain.com
This gives me two primary entries in nginx. I'll send www.domain.com
to /var/www/html2 and lists.domain.com to /var/www/html (though
mailmanweb will kick in before that).
Here's the /etc/nginx/sites-enabled file that works. The entry for
location/ for the mailman section is different from the one you pointed
to, but it is cut and pasted from one of the examples on that site. I
can't find it right now, though -- but it works fine, and life is
short.
Anyway, this works if you clear your browser's cache:
****************************************************
##### paths for www.exampledomain.com #####
#### just goes to /var/www/html2 #####
server {
root /var/www/html2;
index index.html index.htm index.nginx-debian.html;
server_name exampledomain.com, mail.exampledomain.com,
www.exampledomain.com;
location /{
# try_files $uri $uri/ =404;
}
##### added 12/19
listen 443 ssl default_server;
listen [::]:443 ssl default_server;
##########
ssl_certificate
/etc/letsencrypt/live/exampledomain.com/fullchain.pem; # managed by
Certbot
ssl_certificate_key
/etc/letsencrypt/live/exampledomain.com/privkey.pem; # managed by
Certbot
include /etc/letsencrypt/options-ssl-nginx.conf; # managed by
Certbot
ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem; # managed by Certbot
}
##### this for lists.exampledomain, that turns on mailman
server {
root /var/www/html;
index index.html index.htm index.nginx-debian.html;
server_name lists.exampledomain.com;
location /{
proxy_pass http://127.0.0.1:8000;
proxy_set_header Host $host;
proxy_set_header X-Forwarded-For $remote_addr;
#proxy_set_header X-Forwarded-For
$proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Host $host;
proxy_set_header X-Forwarded-Server $host;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_redirect off;
}
location /static/ {
alias /opt/mailman/web/static/;
}
##### added 12/19
listen 443 ssl ;
listen [::]:443 ssl ;
##########
ssl_certificate
/etc/letsencrypt/live/exampledomain.com/fullchain.pem; # managed by
Certbot
ssl_certificate_key
/etc/letsencrypt/live/exampledomain.com/privkey.pem; # managed by
Certbot
include /etc/letsencrypt/options-ssl-nginx.conf; # managed by
Certbot
ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem; # managed by Certbot
}
###### Certbot stuff to force things to 443
server {
if ($host = mail.exampledomain.com) {
return 301 https://$host$request_uri;
} # managed by Certbot
if ($host = www.exampledomain.com) {
return 301 https://$host$request_uri;
} # managed by Certbot
if ($host = lists.exampledomain.com) {
return 301 https://$host$request_uri;
} # managed by Certbot
listen 80 ;
listen [::]:80 ;
server_name www.exampledomain.com lists.exampledomain.com
mail.exampledomain.com exampledomain.com;
return 404; # managed by Certbot
}
********************************************************
3 years, 6 months

[MM3-users] Re: External MTA incoming mail: configuration
by Roland Giesler
On 2024/08/05 19:59, Mark Sapiro wrote:
> I see this reply is now moot as you have now configured list mail to
> go directly to the Mailman server, but ...
>
> On 8/5/24 03:44, Roland Giesler via Mailman-users wrote:
>>
>> In the logs of the MTA I see this however: warning: do not list
>> domain fast.za.net in BOTH virtual_mailbox_domains and relay_domains
>>
>> Mailman creates these entries, but postfix doesn't like it. I don't
>> see any mail delivered to the mailman yet. Is this the problem?
>
> Probably not. It is telling you that mail to the fast.za.net domain
> cannot both be delivered to local mailboxes (virtual_mailbox_domains)
> and relayed to foreign hosts (relay_domains)
>
Thanks, yes, I have since assumed that to be the case.
>
>> In the MTA postfix main.cf:
>>
>> relay_domains = hash:/etc/mailman3/data/postfix_domains
> >
>> cat /etc/mailman3/data/postfix_domains
>> ...
>>
>> and also
>>
>> local_recipient_maps=$virtual_mailbox_maps,
>> hash:/etc/mailman3/data/postfix_lmtp
>>
>> cat /etc/mailman3/data/postfix_lmtp
>> ...
>
> How about
>
> transport_maps = hash:/etc/mailman3/data/postfix_lmtp
I can't remove the $virtual_mailbox_maps entry, since Power-mailinbox
(PMiaB) uses that. It may make Mailman3 work, but break PMiaB).
>
>
>>
>> Then there's:
>> virtual_mailbox_domains=sqlite:/etc/postfix/virtual-mailbox-domains.cf
>>
>> cat /etc/postfix/virtual-mailbox-domains.cf
>> dbpath=/home/user-data/mail/users.sqlite
>> query = SELECT 1 FROM users WHERE email LIKE '%%@%s' UNION SELECT 1
>> FROM aliases WHERE source LIKE '%%@%s' UNION SELECT 1 FROM
>> auto_aliases WHERE source LIKE '%%@%s'
>>
>> When I run that query in sqlite3, it returns no records, so I'm not
>> sure how this is supposed to work. %s to me means that first
>> argument, so is this used in python and then %s is the argument sent
>> to this query?
>
>
> See https://www.postfix.org/sqlite_table.5.html
>
> `%%` is replaced with `%` which is a SQL wildcard matching anything
> and `%s` is replaced by the key postfix is looking for, i.e. the
> domain that it is asking about.
>
> So, that query becomes
>
> SELECT 1 FROM users WHERE email LIKE '%(a)fast.za.net' UNION SELECT 1
> FROM aliases WHERE source LIKE '%(a)fast.za.net' UNION SELECT 1 FROM
> auto_aliases WHERE source LIKE '%(a)fast.za.net'
>
> I.e, it returns true if any user or alias or auto_alias has an address
> ending in '@fast.za.net' and if that's true the mail to any
> '@fast.za.net' address including list mail will be stored locally.
Ah, thank you! I created a ticket at MiaB about this, so I'll post your
response there. The %s had be stumped at first, but now it's clear.
>
> If you really have local users on box2.gtahardware.co.za with
> addresses '@fast.za.net' and you want to relay list mail to lists
> '@fast.za.net', you need to see
> https://docs.mailman3.org/projects/mailman/en/latest/src/mailman/docs/mta.h….
Thank you for that! From that it seems it may still be possible to use
PMiaB as my MTA after, but I'll work through that reference and test it
and report back.
10 months, 3 weeks

[MM3-users] Re: Bulk changes to delivery mode and moderation action
by David Newman
On 1/7/22 4:32 PM, Mark Sapiro wrote:
> On 1/7/22 3:41 PM, David Newman wrote:
>>
>> There are 24 messages in the shunt queue, the most recent of which is
>> a digest from 0000 hours today. The test messages I sent later today
>> are not there.
>>
>> There are also 13 messages in the out queue. I can't read these as the
>> filenames appear to change on every invocation of ls.
>
>
> I suspect an issue trying to connect to the MTA to send the messages.
> This can be caused by permission errors. Check permissions on Mailman's
> var/templates/*
Bingo. This list had regular and digest footer templates with 0644
permissions owned by root:root, and there was an exception and traceback
for the most recent message in shunt about the permissions issue.
I've changed ownership to mailman:mailman and restarted the mailman3
service.
As soon as I fixed this, my inbox filled with test messages...
>
>>> Are there errors and tracebacks in var/logs/mailman.log?
>
>
> Every message in the shunt queue should have an exception and traceback
> logged in mailman.log.
>
>
>> But the Postfix log doesn't show it being distributed to me or anyone
>> else.
>
>
> Is there a 'Cannot connect to SMTP server ... on port ...' anywhere in
> mailman.log?
Yes, lots. This might or might not be a different issue.
As I mentioned earlier, the most recent message in shunt was from 0000
hours today. There are many "Cannot connect" messages since then, but
none since fixing the issue above.
>
>
>> Oddly, neither of the two list owner emails (me and someone else) show
>> this message in the archive via the admin panel. However if I log in
>> as the list owner directly to the archives:
> >
>> https://lists.domain.tld/archives/
>>
>> I can see today's test posts if logged in as the list member, but do
>> not see the posts if logged directly into the archive as the Django
>> superuser.
>
>
> That seems strange, I don't know why the superuser would not be able to
> see things in the archive that a list owner or member can.
Seems OK now. The superuser sees all posts after the unshunt action.
Thanks very much for your help with this.
dn
>
>
>> The nondelivery of list mail is more serious than the archive problem,
>> though.
>
>
> Archiving is separate from delivery. messages can be archived and still
> fail delivery in the out runner which is what's happening here. The
> question is why?
>
> I suspect you have one or more 'Cannot connect to SMTP server ... on
> port ...' messages in mailman.log? and I suspect this is a misleading
> issue in this case caused by an inability to read some file in Mailman's
> var/templates/lists/<list_id>/en directory.
>
> I also suspect the shunted messages are from some prior condition which
> has possibly been fixed, but I can't be sure without exceptions and
> tracebacks from mailman.log (should be timestamped the same as the mod
> time if the shunted file). You can view them with `mailman qfile` and
> unshunt (reprocess) them with `mailman unshunt`.
>
3 years, 5 months

[MM3-users] Re: integrating mm3 with postfix / lmtp
by Fabian A. Santiago
On October 25, 2017 9:17:33 PM EDT, "Fabian A. Santiago" <fsantiago(a)garbage-juice.com> wrote:
>On October 25, 2017 9:13:20 PM EDT, Mark Sapiro <mark(a)msapiro.net>
>wrote:
>>On 10/25/2017 05:41 PM, Fabian A. Santiago wrote:
>>>
>>> No to the domains part and I think virtual alias maps is needed:
>>>
>>> mail postfix/trivial-rewrite[19445]: warning: do not list domain xxx
>>in BOTH virtual_mailbox_domains and relay_domains
>>> Oct 25 20:39:19 mail postfix/trivial-rewrite[19445]: warning: do not
>>list domain xxx in BOTH virtual_mailbox_domains and relay_domains
>>> Oct 25 20:39:19 mail postfix/submission/smtpd[19441]: NOQUEUE:
>>reject: RCPT from
>>pool-108-53-239-102.nwrknj.fios.verizon.net[108.53.239.102]: 550 5.1.1
>><test123@xxx>: Recipient address rejected: User unknown in virtual
>>mailbox table; from=<fsantiago@xxx> to=<test123@xxx> proto=ESMTP
>>helo=<[10.0.0.29]>
>>
>>(above slightly sanitized for return to the list)
>>
>>The issue here is your list domain cannot be a virtual_mailbox_domain
>>or
>>a virtual_alias_domain.
>>
>>I have the same issue on mail.python.org where we have both Mailman 2
>>and Mailman 3 lists @python.org. and python.org is a
>>virtual_alias_domain.
>>
>>I have a group of MRs for a branch that implements "alias_domains" to
>>deal with this.
>>
>>Basically it works by creating another (virtual_alias_maps)
>>postfix_vmap
>>mapping to map list addresses @python.org to addresses @x.python.org.
>>Then the postfix_domains and postfix_lmtp maps have the x.python.org
>>domain and there is a patch to mailman/runners/lmtp.py to map the
>>x.python.org domain back to python.org.
>>
>>The various MRs are
>><https://gitlab.com/mailman/mailman/merge_requests/202> for the core,
>><https://gitlab.com/mailman/mailmanclient/merge_requests/18> for the
>>REST bindings used by Postorius and
>><https://gitlab.com/mailman/postorius/merge_requests/186> to be able
>to
>>set an alias_domain via Postorius.
>>
>>That's not all implemented at mail.python.org. What's there is the
>>basic
>>Postfix config, a bash script the generate the new mappings from the
>>old
>>and a simple patch to mailman/runners/lmtp.py.
>>
>>So, the bottom line is it can be done and it's in process, but it
>won't
>>really be supported until Mailman 3.2. In the mean time, you just need
>>to have a separate domain for your lists that isn't a
>virtual_*_domain.
>
>Ok thanks. At least I have a clear answer now. Any ETA on 3.2 in mind
>yet?
>--
>
>Thanks,
>
>Fabian S.
>
>OpenPGP: 3C3FA072ACCB7AC5DB0F723455502B0EEB9070FC
>_______________________________________________
>Mailman-users mailing list
>mailman-users(a)mailman3.org
>https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/
Mark,
Ok I have it almost perfectly working now having taken your direction and configuring a unique domain not in my email system already.
But in my testing, I replied to a subscription confirmation message and received back an undeliverable looping email error message from postfix. Any clues there you can offer? I can post to the list from any email added via the admin console. The test subscriber address was local to my server. From an outside address, same error.
Once I registered the new email domain, I reverted my postfix config back to the default suggested by maxking's docker instructions.
https://github.com/maxking/docker-mailman
Thanks.
--
Thanks,
Fabian S.
OpenPGP: 3C3FA072ACCB7AC5DB0F723455502B0EEB9070FC
7 years, 8 months

[MM3-users] Re: Fwd: [Django] ERROR (EXTERNAL IP): Internal Server Error: /mailman3/hyperkitty/api/mailman/archive
by David Partain
On Thu, 2021-01-28 at 12:03 -0800, Mark Sapiro wrote:
On 1/28/21 5:33 AM, David Partain via Mailman-users wrote:
I wrote:
I have the same issue, and have changed the configuration in /etc/mailman3/mailman-web.py to:
DATABASES = {
'default': {
'ENGINE': 'django.db.backends.mysql',
'NAME': 'mailman3web',
'USER': 'mailman3web',
'PASSWORD': 'xxxxxxxxxxxxxxxxxx',
'HOST': 'localhost',
'PORT': '',
'OPTIONS': {
'init_command': "SET sql_mode='STRICT_TRANS_TABLES'",
'charset': 'utf8mb4',
},
}
}
and restarted stuff, but I cannot tell that it has changed anything.
You responded:
That should do it. I think the original message should have been saved
as a queue entry in Mailman's var/archives/hyperkitty/spool/ directory.
That directory has all of the messages sent to that list:
# ls /var/lib/mailman3/archives/hyperkitty/spool/
1611827925.8030825+925c996b9b6020ee18e9a689ce23384855159f77.pck 1611827926.1923075+e728f3c29c1fe6eeeca641314cdba7007cb6e132.pck
1611827925.8917305+d16b7004bdbbef98ce40fb8ee70e492715d1607d.pck 1611827926.2623458+1aac13b50d8e7f32eb14d13e6559656aa8f3bd10.pck
1611827925.9594557+7ad2a910b5ee9142c88f0bf26c60c6df960d4262.pck 1611827926.3488555+04a540651c5f829751518433e1c54168ab63a38b.pck
1611827926.0404096+a5e745f51a9f7d541aeb770a89604be17019f3c5.pck 1611827926.4206145+de861eec6404d0c8f9f8bdb180e29bff2de7c52b.pck
1611827926.1167526+0aa63639a4ec102bf63522827637e75e6a2b092a.pck
This is what's expected since the underlying issue isn't yet fixed.
Yes, I'm still seeing the errors. When I send mail to a list with a cute emoji, I see the following in /var/log/mailman3/web/mailman-web.log:
ERROR 2021-01-28 10:58:45,708 16923 django.request Internal Server Error: /mailman3/hyperkitty/api/mailman/archive
(bunch of python errors omitted)
DataError: (1366, u"Incorrect string value: '\\xF0\\x9F\\x98\\x8A\\x0A\\x0A...' for column 'content' at row 1")
OK. The issue is with your database it doesn't like '\xF0\x9F\x98\x8A'
which is a 4-byte utf-8 encoding for a smiley face emoji.
The issue is with MySQL and MariaDB which do not accept 4-byte utf-8
encodings by default. The settings you show above should be sufficient
to allow 4-byte utf-8 encodings.
I'm not that familiar with how the Debian/Ubuntu package sets things up.
Are you sure that /etc/mailman3/mailman-web.py is the settings file used
by Django, and if so does it have at the end something like
```
try:
from settings_local import *
except ImportError:
pass
```
and if so is there something there that overrides the DATABASES setting?
If all that is OK, you may need to do something like
```
ALTER DATABASE mailman3web CHARACTER SET utf8mb4;
ALTER TABLE hyperkitty_email CHARACTER SET utf8mb4;
```
on the database itself.
Hi Mark (and others),
I'm now looking at this again after having to focus on other stuff. I'm befuddled, and I don't really know what to do now.
I did the above.
If I send mail to my list with those bleeping emojis, I see the same errors. In /var/log/mailman3/web/mailman-web.log I see
DataError: (1366, u"Incorrect string value: '\\xF0\\x9F\\x95\\xB5\\xF0\\x9F...
new mail to root, /var/lib/mailman3/archives/hyperkitty/spool/ has a new file, etc.
The mail gets delivered, of course.
If I then look at the database itself, I see:
mysql> use mailman3web;
mysql> SELECT @@character_set_database, @@collation_database;
+--------------------------+----------------------+
| @@character_set_database | @@collation_database |
+--------------------------+----------------------+
| utf8mb4 | utf8mb4_general_ci |
+--------------------------+----------------------+
1 row in set (0.00 sec)
mysql> SHOW TABLE STATUS where name like 'hyperkitty_email';
+------------------+--------+---------+------------+------+----------------+-------------+-----------------+--------------+-----------+----------------+---------------------+-------------+------------+--------------------+----------+----------------+---------+
| Name | Engine | Version | Row_format | Rows | Avg_row_length | Data_length | Max_data_length | Index_length | Data_free | Auto_increment | Create_time | Update_time | Check_time | Collation | Checksum | Create_options | Comment |
+------------------+--------+---------+------------+------+----------------+-------------+-----------------+--------------+-----------+----------------+---------------------+-------------+------------+--------------------+----------+----------------+---------+
| hyperkitty_email | InnoDB | 10 | Dynamic | 133 | 11949 | 1589248 | 0 | 196608 | 4194304 | 150 | 2021-01-29 17:23:13 | NULL | NULL | utf8mb4_general_ci | NULL | | |
+------------------+--------+---------+------------+------+----------------+-------------+-----------------+--------------+-----------+----------------+---------------------+-------------+------------+--------------------+----------+----------------+---------+
1 row in set (0.00 sec)
So, I go look elsewhere...
In /etc/mailman3/mailman.cfg I see:
class: mailman.database.mysql.MySQLDatabase
url: mysql+pymysql://mailman3:NopeNotPastingThat@localhost/mailman3?charset=utf8&use_unicode=1
Should I change the latter to be something like:
url: mysql+pymysql://mailman3:NopeNotPastingThat@localhost/mailman3?charset=utf8mb4&use_unicode=1
?
Cheers,
David
4 years, 4 months

[MM3-users] Re: Join a Mailman 3 list?
by Thomas Ward
On 2025-06-02 20:19, Cathryn McGuire wrote:
> We are Administrators of a small neighbourhood group with more than 20 years of archives.
You'll have to talk to EMWD to see if your archives will be kept with
the migration. They have a completely custom web interface for archival.
---
I'm going to re-state what Mark said here. To quote Mark Sapiro:
> As far as your EMWD migration from cPanel Mailman 2.1 to Mailman 3 is
conerned, I think you'll find little if any change as far as email
posting to the list and email from the list is concerned, but EMWD has
their own proprietary web UI for list management and archiving, so the
web UI at EMWD is quite different from that for this list.
THEREFORE...
> We love the simple functionality of Mailman 2.
> One post goes to the entire membership by email. Any reply arrives by email; either immediately or as part of the 9:00 am Digest.
That part isn't going to change.
> No websites or browsers or sign-ins.
Well, you manage your list SOMEHOW, probably with EMWD's web panel and
UI panel.
> No threads or topics.
There's no "threads" like forums have, but discussions by topic at least
in mailman 2 and mailman 3 have still existed and probably still will
exist.
> Simply emails back and forth.
>
> Does Mailman 3 have the ability to function this way?
(Read my last statements)
> Might someone invite us to temporarily join their group so we can see how Mailman 3 operates from the point of view of members?\
EMWD uses their **own custom UI** for management and archiving. This
means that we can't give you any real guidance on EMWD and such for how
it relates to user management, etc. because the standard Mailman 3 UI
(Postorious) for that won't be what you use with EMWD. So we can't
really assist you to see how things will be from the view of "members of
the list" in that front.
For the vast majority of users and use cases though, if all they care
about is the email messages being sent to the list and received from the
list, nothing will change for users. It's the *management* components
and EMWD's custom UIs you'll have to work with though, not the standard
Postorious Mailman3 UI.
At my dayjob, we use mailing lists here on Mailman3, albeit with the
standard Postorious UI, but we have a separate management UI that we use
for managers to check who is a member, remove members, etc. that uses
the Mailman API and not Postorious, but the core management group
(myself and IT staff) use Postorious for our management tasks and to see
if Mailman is working and such. Additionally, we have 53 lists and well
over a thousand members on some of othe lists and it works well. The
vast majority of the members only care that the email functionality
works, and it does for them. (None of them use digest format mail
notifications, but that's because the lists tend to be more 'realtime'
for those members.) (And before you ask, those lists are not open)
If you have *more specific* questions beyond "do the same basics of
Mailman2 like digests, email handling, etc. still behave more or less
the same way" then you should ask those questions *specifically*.
If your specific questions revolve around the management interface, you
have to talk to EMWD. Same with message archives.
Thomas
1 month

[MM3-users] Re: Templates
by David Krantz
Hi again,
I had the problem with getting two footers, i.e. two expansions of the
template. After some digging in the source code I found out that the
decorator made one expansion (without personalization) and that the
delivery handling made another (with personalization). So I hacked
pipelines/builtin.py with a new pipeline that excluded the decorate
step, recompiled and changed to that pipeline for my personalized
list. That worked. Nothing like a bit of shotgun debugging in
production.
That solves my immediate problem. Is there a known and recommended way
of configuring personalized delivery so that you only get the
personalized footer? I have ideas, but I probably should share them
with the developer list instead. :-)
Of course this very nice functionality is a bit buried. I activated it
using the interactive python shell, seems less risky than changing the
database directly.
Cheers
// David
On Sat, Sep 23, 2017 at 10:39 PM, David Krantz <gazorg(a)gmail.com> wrote:
> On Sat, Sep 23, 2017 at 6:48 PM, Mark Sapiro <mark(a)msapiro.net> wrote:
>>
>> Have you tried restarting/reloading whatever dbm (MySQL, PostgreSQL, ?)
>> you are using?
>
> No, that would have been strange to me; the table in the database was
> up to date. But now I tried that, I got no effect this time but I
> probably could set up a better test.
>
> I also had another problem [solved]: I get the error message "Multiple
> rows were found for one_or_none" when I try TemplateManager.get(name,
> context) for the list. There is only one matching row in the templates
> table so something is fishy with the ORM. This occured when I changed
> to the previous uri value. As the database does not have any
> duplicates in the templates table I suspect either a broken join or
> that the cache retains the old value.
>
> The traceback looks like this in the mailman shell:
>>>> tm.get('list:member:regular:footer', 'test.example.com')
> Traceback (most recent call last):
> File "<console>", line 1, in <module>
> File ".../venv-3.5/lib/python3.5/site-packages/mailman-3.2.0a1-py3.5.egg/mailman/database/transaction.py",
> line 85, in wrapper
> return function(args[0], config.db.store, *args[1:], **kws)
> File ".../venv-3.5/lib/python3.5/site-packages/mailman-3.2.0a1-py3.5.egg/mailman/model/template.py",
> line 98, in get
> contents = cache_mgr.get(actual_uri)
> File ".../venv-3.5/lib/python3.5/site-packages/mailman-3.2.0a1-py3.5.egg/mailman/database/transaction.py",
> line 85, in wrapper
> return function(args[0], config.db.store, *args[1:], **kws)
> File ".../venv-3.5/lib/python3.5/site-packages/mailman-3.2.0a1-py3.5.egg/mailman/model/cache.py",
> line 125, in get
> CacheEntry.key == key).one_or_none()
> File ".../venv-3.5/lib/python3.5/site-packages/SQLAlchemy-1.2.0b2-py3.5-linux-x86_64.egg/sqlalchemy/orm/query.py",
> line 2814, in one_or_none
> "Multiple rows were found for one_or_none()")
> sqlalchemy.orm.exc.MultipleResultsFound: Multiple rows were found for
> one_or_none()
>
> Workaround: Delete cached files in .../var/cache and run delete from
> file_cache in postgresql. Then that works again. The culprit was that
> the file got cached twice so there is a bug in the cache function. I
> used the ITemplateManager-util in the shell to cause the problem.
>
>>> 2. the $user_delivered_to and $user_email do not expand for some
>>> reason. Known problem?
>>
>>
>> These require that the list delivery be personalized. See
>> <http://mailman.readthedocs.io/en/latest/src/mailman/runners/docs/outgoing.h…>.
>>
>
> That explains things. Thank you!
>
> Now I got two footers, first one without personalisation and one
> personalised. Interesting.
>
> best regards
> // David
7 years, 9 months

[MM3-users] Re: psycopg2 error?
by Odhiambo Washington
On Fri, Oct 27, 2023 at 8:21 PM Mark Sapiro <mark(a)msapiro.net> wrote:
> On 10/27/23 09:16, Odhiambo Washington wrote:
> > (venv) mailman@debian12:~$ pip cache remove psycopg2-binary
> > WARNING: No matching packages for pattern "psycopg2-binary"
> > Files removed: 0
>
> This was intended to prevent the following 'Using cached'.
>
>
> > (venv) mailman@debian12:~$ pip install psycopg2-binary
> > Collecting psycopg2-binary
> > Using cached
> >
> psycopg2_binary-2.9.9-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
> > (3.0 MB)
>
>
> However, you now have a different issue.
>
>
> > raise DistributionNotFound(req, requirers)
> > pkg_resources.DistributionNotFound: The 'flufl.lock>=5.1' distribution
> was
> > not found and is required by mailman
>
> See https://gitlab.com/mailman/mailman/-/issues/1085
Thank you. That solves the problem for sure! But this was detected 4 months
ago. When is the permanent solution coming?
(venv) mailman@debian12:~$ vi
venv/lib/python3.11/site-packages/mailman-3.3.9.egg-info/requires.txt #
flufl.xxx to flufl-xxx
(venv) mailman@debian12:~$ mailman info
GNU Mailman 3.3.9 (Tom Sawyer)
Python 3.11.2 (main, Mar 13 2023, 12:18:29) [GCC 12.2.0]
config file: /etc/mailman3/mailman.cfg
db url: postgresql://mailman:XXXXXXX@localhost/mailman
devmode: DISABLED
REST root url: http://localhost:8001/3.1/
REST credentials: restadmin:restpass
(venv) mailman@debian12:~$ exit
logout
root@debian12:/home/wash# systemctl start mailman3
root@debian12:/home/wash# systemctl status mailman3
● mailman3.service - GNU Mailing List Manager
Loaded: loaded (/etc/systemd/system/mailman3.service; enabled; preset:
enabled)
Active: active (running) since Sat 2023-10-28 01:22:56 EAT; 7s ago
Process: 15590 ExecStart=/opt/mailman/venv/bin/mailman start
(code=exited, status=0/SUCCESS)
Main PID: 15592 (python3)
Tasks: 17 (limit: 4547)
Memory: 980.8M
CPU: 27.774s
CGroup: /system.slice/mailman3.service
├─15592 /opt/mailman/venv/bin/python3
/opt/mailman/venv/bin/master -C /etc/mailman3/mailman.cfg
├─15598 /opt/mailman/venv/bin/python3
/opt/mailman/venv/bin/runner -C /etc/mailman3/mailman.cfg
--runner=archive:0:1
├─15599 /opt/mailman/venv/bin/python3
/opt/mailman/venv/bin/runner -C /etc/mailman3/mailman.cfg
--runner=bounces:0:1
├─15600 /opt/mailman/venv/bin/python3
/opt/mailman/venv/bin/runner -C /etc/mailman3/mailman.cfg
--runner=command:0:1
├─15601 /opt/mailman/venv/bin/python3
/opt/mailman/venv/bin/runner -C /etc/mailman3/mailman.cfg --runner=in:0:1
├─15602 /opt/mailman/venv/bin/python3
/opt/mailman/venv/bin/runner -C /etc/mailman3/mailman.cfg --runner=lmtp:0:1
├─15603 /opt/mailman/venv/bin/python3
/opt/mailman/venv/bin/runner -C /etc/mailman3/mailman.cfg --runner=nntp:0:1
├─15604 /opt/mailman/venv/bin/python3
/opt/mailman/venv/bin/runner -C /etc/mailman3/mailman.cfg --runner=out:0:1
├─15605 /opt/mailman/venv/bin/python3
/opt/mailman/venv/bin/runner -C /etc/mailman3/mailman.cfg
--runner=pipeline:0:1
├─15606 /opt/mailman/venv/bin/python3
/opt/mailman/venv/bin/runner -C /etc/mailman3/mailman.cfg --runner=rest:0:1
├─15607 /opt/mailman/venv/bin/python3
/opt/mailman/venv/bin/runner -C /etc/mailman3/mailman.cfg --runner=retry:0:1
├─15608 /opt/mailman/venv/bin/python3
/opt/mailman/venv/bin/runner -C /etc/mailman3/mailman.cfg --runner=task:0:1
├─15609 /opt/mailman/venv/bin/python3
/opt/mailman/venv/bin/runner -C /etc/mailman3/mailman.cfg
--runner=virgin:0:1
├─15610 /opt/mailman/venv/bin/python3
/opt/mailman/venv/bin/runner -C /etc/mailman3/mailman.cfg
--runner=digest:0:1
├─15648 /opt/mailman/venv/bin/python3
/opt/mailman/venv/bin/runner -C /etc/mailman3/mailman.cfg --runner=rest:0:1
└─15649 /opt/mailman/venv/bin/python3
/opt/mailman/venv/bin/runner -C /etc/mailman3/mailman.cfg --runner=rest:0:1
Oct 28 01:22:54 debian12.wash.lan systemd[1]: Starting mailman3.service -
GNU Mailing List Manager...
Oct 28 01:22:55 debian12.wash.lan mailman[15590]: Starting Mailman's master
runner
Oct 28 01:22:55 debian12.wash.lan mailman[15590]: Generating MTA alias maps
Oct 28 01:22:56 debian12.wash.lan systemd[1]: mailman3.service: Can't open
PID file /opt/mailman/mm/var/master.pid (yet?) after start: No such file or
directory
Oct 28 01:22:56 debian12.wash.lan systemd[1]: Started mailman3.service -
GNU Mailing List Manager.
root@debian12:/home/wash#
--
Best regards,
Odhiambo WASHINGTON,
Nairobi,KE
+254 7 3200 0004/+254 7 2274 3223
"Oh, the cruft.", egrep -v '^$|^.*#' ¯\_(ツ)_/¯ :-)
[How to ask smart questions:
http://www.catb.org/~esr/faqs/smart-questions.html]
1 year, 8 months

[MM3-users] Re: Different Mail Domain Cause Key Error
by Brian Carpenter
On 4/21/20 4:04 PM, Mark Sapiro wrote:
> This is not the error. The KeyError ... 'file' exception is a Django
> logging exception. It is not the underlying error. There should be more
> in the log indicating what the real problem is.
Ok. The first thing however is did I miss a step?
Here is the complete error that is sent to me via email as superuser:
Internal Server Error:/mailman3/lists/
KeyError at/mailman3/lists/
'file'
Traceback:
File "/opt/mailman/mm/venv/lib/python3.7/site-packages/django/core/handlers/exception.py" in inner
34. response = get_response(request)
File "/opt/mailman/mm/venv/lib/python3.7/site-packages/django/core/handlers/base.py" in _get_response
115. response = self.process_exception_by_middleware(e, request)
File "/opt/mailman/mm/venv/lib/python3.7/site-packages/django/core/handlers/base.py" in _get_response
113. response = wrapped_callback(request, *callback_args, **callback_kwargs)
File "/opt/mailman/mm/venv/lib/python3.7/site-packages/postorius/views/list.py" in list_index
755. paginator_class=MailmanPaginator)
File "/opt/mailman/mm/venv/lib/python3.7/site-packages/django_mailman3/lib/paginator.py" in paginate
71. objects = paginator.page(page_num)
File "/opt/mailman/mm/venv/lib/python3.7/site-packages/django_mailman3/lib/paginator.py" in page
46. number = self.validate_number(number)
File "/opt/mailman/mm/venv/lib/python3.7/site-packages/django/core/paginator.py" in validate_number
48. if number > self.num_pages:
File "/opt/mailman/mm/venv/lib/python3.7/site-packages/django/utils/functional.py" in __get__
80. res = instance.__dict__[self.name] = self.func(instance)
File "/opt/mailman/mm/venv/lib/python3.7/site-packages/django/core/paginator.py" in num_pages
97. if self.count == 0 and not self.allow_empty_first_page:
File "/opt/mailman/mm/venv/lib/python3.7/site-packages/django/utils/functional.py" in __get__
80. res = instance.__dict__[self.name] = self.func(instance)
File "/opt/mailman/mm/venv/lib/python3.7/site-packages/django_mailman3/lib/paginator.py" in count
56. return self.function(count=0, page=1).total_size
File "/opt/mailman/mm/venv/lib/python3.7/site-packages/postorius/views/list.py" in _get_list_page
751. advertised=advertised, mail_host=mail_host, count=count, page=page)
File "/opt/mailman/mm/venv/lib/python3.7/site-packages/mailmanclient/client.py" in get_list_page
181. return Page(self._connection, url, MailingList, count, page)
File "/opt/mailman/mm/venv/lib/python3.7/site-packages/mailmanclient/restbase/page.py" in __init__
37. self._create_page()
File "/opt/mailman/mm/venv/lib/python3.7/site-packages/mailmanclient/restbase/page.py" in _create_page
62. response, content = self._connection.call(self._build_url())
File "/opt/mailman/mm/venv/lib/python3.7/site-packages/mailmanclient/restbase/connection.py" in call
112. error_msg, response, None)
*During handling of the above exception (HTTP Error 404: {"title": "404
Not Found"}), another exception occurred:*
File "/opt/mailman/mm/venv/lib/python3.7/site-packages/django/core/handlers/exception.py" in inner
34. response = get_response(request)
File "/opt/mailman/mm/venv/lib/python3.7/site-packages/postorius/middleware.py" in __call__
42. return self.get_response(request)
File "/opt/mailman/mm/venv/lib/python3.7/site-packages/django/core/handlers/exception.py" in inner
36. response = response_for_exception(request, exc)
File "/opt/mailman/mm/venv/lib/python3.7/site-packages/django/core/handlers/exception.py" in response_for_exception
95. exc_info=sys.exc_info(),
File "/opt/mailman/mm/venv/lib/python3.7/site-packages/django/utils/log.py" in log_response
228. exc_info=exc_info,
File "/usr/lib/python3.7/logging/__init__.py" in error
1412. self._log(ERROR, msg, args, **kwargs)
File "/usr/lib/python3.7/logging/__init__.py" in _log
1519. self.handle(record)
File "/usr/lib/python3.7/logging/__init__.py" in handle
1529. self.callHandlers(record)
File "/usr/lib/python3.7/logging/__init__.py" in callHandlers
1591. hdlr.handle(record)
File "/usr/lib/python3.7/logging/__init__.py" in handle
905. self.emit(record)
File "/opt/mailman/mm/venv/lib/python3.7/site-packages/django/utils/log.py" in emit
119. reporter = ExceptionReporter(request, is_email=True, *exc_info)
File "/opt/mailman/mm/venv/lib/python3.7/site-packages/django/views/debug.py" in __init__
254. self.template_info = getattr(self.exc_value, 'template_debug', None)
File "/usr/lib/python3.7/tempfile.py" in __getattr__
614. file = self.__dict__['file']
Exception Type: KeyError at/mailman3/lists/
Exception Value: 'file'
Request information:
USER: AnonymousUser
--
Please let me know if you need further assistance.
Thank you for your business. We appreciate our clients.
Brian Carpenter
EMWD.com
--
EMWD's Knowledgebase:
https://clientarea.emwd.com/index.php/knowledgebase
EMWD's Community Forums
http://discourse.emwd.com/
5 years, 2 months

[MM3-users] [SOLVED] Re: Re: Newbie question 2: Rewriting issue for bounced emails
by William Oliver
On Mon, 2021-12-27 at 14:36 -0800, Mark Sapiro wrote:
>
> It appears that the MX for billoblog.com is not accepting mail from
> your
> server. Can you send non-mailman mail from this server to this address?
> If not, you need to contact billoblog.com to fin wht they are blocking
> your mail.
>
> > I tried changing the smtp port in mailman.cfg to 587, but that didn't
> > change anything.
>
> because the issue is not in delivery from Mailman to Postfix. It is in
> delivery from Postfix to billoblog.com.
First, thanks so much for talking me through this. I could never have
done it on my own. If you ever decide to go to the Smoky Mountain
National Park or Knoxville, TN, send me an email, and I'll buy you a
drink (I live in the hills between Knoxville and Gatlinburg, TN).
In any case, I did some wandering around the intertubes and it appears
this is an uncommon but well-known problem when using dovecot and
postfix. It has to do with the setting of
smtpd_recipient_restrictions
in master.cf.
It's not clear *which* "reject" command is triggered, but if I set it
to just:
-o smtpd_recipient_restrictions=permit_sasl_authenticated
then it can get through. Er, to the next error, anyway. Sigh.
I have *no* idea why it only shows up with mailman, but not with
regular mail. I got some learnin' to do about that line.
I don't know what the default reject criteria are. I have this
horrible suspicion that I've opened myself up to zillions of evil
emails, but I'll investigate that later.
So, this took care of the Access Denied issue. That opened up the next
error, which was "relay access denied". Again, regular mail worked
just fine.
Here's the syslog when I sent email to testlist from
fp145(a)libertyfp.org:
Here's the rejection to billo(a)billoblog.com:
Dec 27 18:31:52 libertyfp postfix/submission/smtpd[471207]: connect
from mail.libertyfp.org[2.56.57.28]
Dec 27 18:31:52 libertyfp postfix/submission/smtpd[471207]: NOQUEUE:
reject: RCPT from mail.libertyfp.org[2.56.57.28]: 454 4.7.1
<billo(a)billoblog.com>: Relay access denied;
from=<testlist-bounces+billo=billoblog.com(a)libertyfp.org>
to=<billo(a)billoblog.com> proto=ESMTP helo=<mail.libertyfp.org>
Dec 27 18:31:52 libertyfp postfix/submission/smtpd[471207]: disconnect
from mail.libertyfp.org[2.56.57.28] ehlo=1 mail=1 rcpt=0/1 rset=1
quit=1 commands=4/5
But it accepts the email to fp145(a)libertyfp.org
Dec 27 18:31:53 libertyfp postfix/submission/smtpd[471207]: connect
from mail.libertyfp.org[2.56.57.28]
Dec 27 18:31:53 libertyfp postfix/submission/smtpd[471207]: 4FCDD420F5:
client=mail.libertyfp.org[2.56.57.28]
Dec 27 18:31:53 libertyfp postfix/cleanup[471223]: 4FCDD420F5: message-
id=<8d3bf47c5dcd86983e8c01f8baece4e3ac43a1a1.camel(a)libertyfp.org>
Dec 27 18:31:53 libertyfp postfix/cleanup[471223]: 4FCDD420F5: warning:
header Subject: [Testlist] bbbbb from mail.libertyfp.org[2.56.57.28];
from=<testlist-bounces+fp145=libertyfp.org(a)libertyfp.org>
to=<fp145(a)libertyfp.org> proto=ESMTP helo=<mail.libertyfp.org>
Dec 27 18:31:53 libertyfp postfix/qmgr[468573]: 4FCDD420F5:
from=<testlist-bounces+fp145=libertyfp.org(a)libertyfp.org>, size=1870,
nrcpt=1 (queue active)
Dec 27 18:31:53 libertyfp postfix/submission/smtpd[471207]: disconnect
from mail.libertyfp.org[2.56.57.28] ehlo=1 mail=1 rcpt=1 data=1 quit=1
commands=5
Direct mail from fp145(a)libertyfp.org to billo(a)billoblog.com worked fine
also.
Again, a quick DuckDuckGo search reveals that this has come up a couple
of times. It required that I modify /etc/postfix/main.cf to add the
non-localhost ip4 address of the box to the mynetworks line:
mynetworks = 127.0.0.0/8 10.0.0.0/24
to
mynetworks = 127.0.0.0/8 10.0.0.0/24 2.56.57.28
I assume that means that postfix uses localhost for regular mail, but
mailman3 uses the 2.56.57.28 address.
In any case, it now works fine. I am happily receiving the six million
test messages that were queued awaiting delivery to
billo(a)billoblog.com.
Once again, thanks. I owe you.
billo
3 years, 6 months

[MM3-users] Re: Splitting hosts: mta&core vs postorius
by Andrew Hodgson
Stephen J. Turnbull wrote:
>Ruth Ivimey-Cook writes:
> > On 21/06/2020 04:52, Mark Sapiro wrote:
> > > Change that to greyarea-post
> > Problem is, if I do that (which I did in the beginning), the core rest > service listens on localhost / 127.0.0.1
>I don't understand. I'm not in a position to test with Mailman itself right now, but the standalone gunicorn[1] does the right thing (takes an IP address and binds to the corresponding interface, or takes a domain name, resolves it to >the IP address, and binds that to the corresponding interface). It does not substitute localhost.
Sorry not to reply to ruth on this before, my main experience of this issue was running in a Kubernetes cluster using Docker, using https://github.com/maxking/docker-mailman as the basis for the images. What follows is my own research on this issue and it may be completely wrong.
Taking the default Mailman Core setting:
[webservice] hostname: localhost
This makes Mailman-Core listen on the loopback address (via name lookup) on the configured port for incoming REST requests. When it responds to these requests, it sends out in the response a self_link address which matches the [webservice] hostname Parameter. Connecting clients (such as Postorius) need to connect to Mailman-Core on the given hostname (eg http://localhost in the default case where Mailman Core and Web components are installed to the same machine.
However if the [webservice] hostname: parameter is set to something like 0.0.0.0, then although you can direct Postorius (via DNS lookup or IP address) at the Mailman Core instance, it fails to work properly because the resulting response sent back from Mailman Core will include self_links pointing at 0.0.0.0 which will not be usable as a URL by the REST client.
A fix for this issue is to set the [webservice] hostname parameter to a FQDN or IP address which can be resolved by the machine running the Web components, and as long as the base URL that Postorius tries to use for the Mailman Core access is the same as in the [webservice] hostname parameter, you are good to go.
It appears that when specifying a FQDN in the [webservice] hostname parameter, that the system will look up the IP address for that host using the systems name resolution function. This has the side affect of potentially listening on the wrong interface (localhost) if the system hosts file is set such that the machine's FQDN points to 127.0.0.1. In my case my containers were behind CoreDNS and this wasn't an issue for me, but had I tried this for example on a Debian system I would have come against the same issue that Ruth has as it will automatically set the FQDN of the system to resolve to 127.0.0.1 by way of the Hosts file. Adding the network IP address of the system with the FQDN in the hosts file should fix this issue.
> > IMO, the hostname parameter needs to be split up into a "what address > should the rest of the world use to address me" and separately "what > address(es) should I listen on". Multiple listen addresses enable > multihomed >hosts to get the right connectivity, too.
>I'm not clear on what you're saying. An address is a rendezvous point; if you're not listening on the address that others are using, you won't meet. What good does it do to split them up?
I agree with this, we need a setting for which interface for Gunicorn to listen on, and what Mailman Core sends out in the self_link attribute when responding to REST requests.
Thanks.
Andrew.
5 years

[MM3-users] Re: Help with some 'withlist' configuration changes
by David Partain
Hi!
Thank you, Mark, for giving me something to go on! I'll dig further.
Cheers,
David
On Wed, 2021-06-23 at 06:59 -0700, Mark Sapiro wrote:
On 6/23/21 6:30 AM, David Partain via Mailman-users wrote:
Hi,
Firstly, a repeat that I have a relatively broken (and soon to be fixed, I hope) installation of mailman3 based on Ubuntu 18.04 distrib packages (3.1.1-9) that stumbles along by me dealing with a bunch of things by hand that I hope'll go away once I'm up to the current version.
In this set-up, I get a fair number of items shunted. Since I have this wonky version where stuff isn't always exposed in the web interface, I have to fix these things by hand. An example is that something gets shunted because of too many recipients, where I do:
sudo -u list mailman withlist somemailmanlist
m.max_num_recipients = 0
commit()
sudo -u list mailman unshunt
I've managed to find a number of these, such as m.max_message_size, m.require_explicit_destination, and m.administrivia.
There is some other issue here as these things should only cause a
message to be held, not shunted. Some exception is being thrown in the
process of holding the messgage, and thaty is the real issue. What are
the tracebacks in Mailman's mailman.log for these shunts?
My questions are undoubtedly foolish, but here goes:
1. Is there any way to print the entire 'm' structure? If so, I'd perhaps be able to figure out the answers to my other questions.
dir(m)
or maybe you want
>>> for x in dir(m):
... if not x.startswith('_'):
... print(f'{x}: {m.__getattribute__(x)}')
...
2. Is there a way for me to correct the following shunt-ing issues with 'withlist'? I've been unable to figure out how...
a. 'moderation_reasons': [ 'Message has no subject'] / 'rule_hits': ['no-subject']
b. Some things get caught as 'rule_hits': ['nonmember-moderation']. However, if I look in the (web-based) config, it shows that non-members should be accepted but the messages are shunted nonetheless. I don't know what to look for in 'm' or how I might clear these messages.
As I note above, these things are reasons to hold the message. The
shunting occurs because something is going wrong in the holding process.
Find the errors and tracebacks in Mailman's mailman.log to see what the
real issue might be.
3. I have no idea what these are telling me to do about digest messages. Suggestions? This is the entire info I get from 'mailman qfile':
------------------------------------------------------snip snip----------------------------------------------
[----- start pickle -----]
<----- start object 1 ----->
<----- start object 2 ----->
{ '_parsemsg': False,
'digest_number': 457,
'digest_path': '/var/lib/mailman3/lists/somelist/digest.31.457.mmdf',
'lang': 'en',
'listid': 'somelistid',
'version': 3,
'volume': 31,
'whichq': 'digest'}
[----- end pickle -----]
------------------------------------------------------snip snip----------------------------------------------
That is telling you there was in issue in sending the digest, the
mailbox for which is
/var/lib/mailman3/lists/somelist/digest.31.457.mmdf. Unshunting that
will retry sending that digest.
4. I have some that have 'rule_hits': [] (it's empty) but are shunted nonetheless. I can't see anything weird other than one of the messages has a utf-8 subject. Any ideas?
5. Some messages that were sent to -request addresses (e.g., subscribe messages, confirm, approve messages) are being shunted. What should I do with these?
You need to find the errors in the log and figure out what the
underlying issue is. I'm guessing it's a permissions issue, possibly
because of having at one time rum `mailman start` as root causing files
to be created and owned by root and not be readable/writable by the
Mailman user.
4 years

[MM3-users] Re: mailman3 does not send to the members of the lists
by Stephen J. Turnbull
Mark Sapiro writes:
> I say you have to understand what you want Postfix to do and configure
> it appropriately.
I would recommend going to a Postfix list as Mark suggested. Postfix
configuration is complex, and they're more likely to know the best way
to do exactly what you say you want to do. I myself can't help with
Postfix details, I'm an Exim user. But my list of "need to know"
stuff is generic, just the answers would be very different with Exim
or Sendmail or qmail!
> I would need much more information in order to know how your Postfix
> should be configured,
In particular, whoever answers your questions will need to know:
1. Why are you using virtual domains for email? This doesn't need to
have great detail. Mostly:
- are you supporting multiple organizations with their own domains, OR
- is this for some purpose of your own, OR
- did you just copy the virtual domain lines from some example
configuration?
In the last case, you might try not even mentioning that you're
using virtual domains. (That's only if you treat this as a "new
install". If you're going to send them your current configs,
they'll see your virtual domain stuff and want to know "why?" You
may as well tell them.) They may tell you that you can do
everything you want without them! Or they may tell you that
virtual domains are the best way to do that, and you can be
confident about it.
In the last case you could also try just deleting and seeing if
your system works, as you suggested to Mark earlier. But that
could also break everything related to mail on that host.
2. Who is receiving mail via Dovecot, and via what domain(s)? The
"who" is generic (eg, "users and web applications using IMAP
clients"), but the domains should be specific.
If not inconvenient, it is easiest if you give real names for the
domains. If there are privacy, security, or intellectual property
concerns with the domain names, you'll need to find out the
conventions used by the Postfix community for dealing with that.
If you do redact your domain names in your explanation in the
initial contact, make sure you explain exactly how you did that,
or you will confuse everybody and have an unpleasant experience.
3. What domain does Mailman use to receive mail?
Is Mailman the only thing that receives mail on that domain?
What else, if anything, needs to received mail addressed to that
domain?
4. What domains other than those handled by Mailman and Dovecot, if
any, are processed by your Postfix MTA?
5. What other things, if any, besides Mailman and Dovecot directly
receive mail processed by your Postfix MTA?
Anything downstream from Mailman and Dovecot doesn't need to be
mentioned. If there are still problems with downstream recipients
once Mailman and Dovecot are receiving mail correctly, direct
those issues to us and to Dovecot, as appropriate.
You should check the channel FAQ to see whether they want your
configuration in your first contact, or not. Even if they do, you
might be better off to treat this as a "new install" rather than "it's
broken, help me fix it".
In contacting the Postfix channel, explain "I want to ..." based on
the answers to those questions. Then your question is "how do I
configure mail so that Dovecot domains and users get mail, Mailman
domains, lists, and administrators get mail, and any other mail
handled by Postfix goes to the right place (as defined by questions 4
and 5)?"
Steve
4 years, 11 months

[MM3-users] Re: Problems with New MM3 Installation
by Abhilash Raj
On Tue, May 11, 2021, at 8:43 PM, Mark Sapiro wrote:
> On 5/11/21 7:46 PM, Jeff wrote:
> >
> > I really appreciate your assistance. New messages are now being archived as expected, but I still have a few small remaining issues to work out with my MM3 installation:
> >
> > 1) some emails that arrived before I got the archive working are still sitting in:
> >
> > /usr/local/mailman3/mm/var/archives/prototype/[listname]@[domain]/new
> >
> > Strangely this includes at least one email that was archived. Should this directly be cleared as messages are archived? Is there a way to force it to be cleared?
>
> /usr/local/mailman3/mm/var/archives/prototype/[listname]@[domain] is a
> collection of messages in maildir format. This is how the prototype
> archiver stores messages. This has nothing to do with HyperKitty. It is
> a separate archiver. If you don't want messages to be stored there, you
> can disable the prototype archiver for the list by unchecking prototype
> in Postorius -> Settings -> Archiving -> Active archivers or disable it
> entirely for the installation by setting
> ```
> [archiver.prototype]
> enable: no
> ```
> in mailman.cfg
>
> > 2) Some messages that arrived while I was having other problems with the setup have been stored in:
> >
> > /usr/local/mailman3/mm/var/queue/shunt
> >
> > What should I do to get these messages processed?
>
>
> Assuming the issues that caused them to be shunted have been fixed, just
> run the command
> ```
> mailman unshunt
> ```
>
> > 3) Similar to above, some messages are in:
> >
> > /usr/local/mailman3/mm/var/queue/bad
> >
> > How can I get these messages processed?
>
>
> First examine the messages with
> ```
> mailman qfile /usr/local/mailman3/mm/var/queue/bad/<file>
> ```
> To be sure you want them. Also examine mailman.log for the times they
> were stored in the `bad` queue. You are looking for 'Skipping and
> preserving unparseable message: <file>' and/or 'SHUNTING FAILED,
> preserving original entry: <file> messages and you want to determine
> which runner preserved the message. There may be a 'whichq' entry in the
> message's metadata in which case, that's the answer.
>
> Once you have determined the queue, you can just move the .psv file from
> the bad queue to the appropriate queue, renaming it from .psv to .pck in
> the process.
>
>
> > 4 Modified the template for “list:admin:action:post” through Postorious and emails that arrived after that were put in the “shunt” queue. I traced this problem to POSTORIUS_TEMPLATE_BASE_URL. By default, it is set to "http://localhost:8000 <http://localhost:8000/>” which is where uwsgi is listening. However, uwsigi is listening for uwsgi:/ not http://. Should I change POSTORIUS_TEMPLATE_BASE_URL to “uwsgi://localhost:8000 <uwsgi://localhost:8000>” or keep http but make it something else?
>
>
> I know little about uwsgi. setting it to `uwsgi://localhost:8000` might
> work. You could also set it to the base URL that a user would use to
> access the web UI, e.g. `https://example.com` and that would presumably
> be proxied to uwsgi. For example, on the server for this list we have
> ```
> POSTORIUS_TEMPLATE_BASE_URL = 'https://lists.mailman3.org'
> ```
> which gets proxied to gunicorn, but the idea is the same.
Using the full external URL should work. Core doesn’t speak uwsgi protocol
so the uwsgi:// URL won’t actually work.
I am starting to think it was a very bad idea to use uwsgi in the official docs :(
--
thanks,
Abhilash Raj (maxking)
4 years, 1 month

[MM3-users] Re: How To Install Mailman 3 on Debian 10 (Complete Guide)
by Brian Carpenter
On 2/26/21 10:00 PM, Stephen J. Turnbull wrote:
> Thank you for going to the trouble of making your guide easily
> available to and usable by the community.
You're welcome Steve.
> Yes, and we try to document them all, written by different people at
> different times. I don't think that's an unreasonable approach given
> the wide variety of situations of our site admins, but I'm sure a lot
> of "greenfield" installations will appreciate your thorough, "from
> parts manifest to assembled working system", approach.
I agree. I just know there are probably a lot of folks who just want a
working and current Mailman 3 server and are not picky over the actual
server environment. Mailman 3 is really dependent upon being connected
to a number of services: web server, database server and MTA for
instance. Then you add in all of the required Python modules, and you
have a really complicated system that has a lot of moving parts.
I intend to explore other OS for installing MM3 and to document that
process as well. I will not document the process of using package
managers (apt/yum) etc to install Mailman 3 itself because I think it is
very problematic having older versions of Mailman 3 set up. Mark Sapiro
put it very well when he said:
> Mailman 3 is still relatively young and there are many important
> features and fixes in the current releases that aren't in the
> Debian/Ubuntu packages.
I hoping a guide such as mine will move folks away from using a Debian
repo for Mailman installations.
> Yes, it has been a problem. At this point I'm pretty sure :^þ that
> mailman.readthedocs.io is the official guide, but that hasn't been
> well-known in the past and there are a lot of mirrors and unofficial
> guides like yours (but not as thorough). And there's a lot of stuff
> on the Wiki that requires effort to integrate because it was
> originally written in reply to a particular user's questions.
See that is something I am very interested in fixing and cleaning up but
I need help in knowing how to work with something like Readthedocs.io.
> Sphinx is pretty much the gold standard for Python documentation. It
> looks nice. The markup is reStructuredText, which is a powerful,
> Markup-like language with a few features that Markup didn't have last
> I looked, and it's extensible by Python programmers. It's also used
> in marking up Python docstrings. So you can see why we'd choose it.
> But if you're *not* an experienced Python programmer, none of those
> are advantages.
Exactly!
> > > I am just trying to understand how can we lower the barrier for
> > > community members to help contribute to existing docs instead of
> > > them having to create new ones. Specifically around installation,
> > > since that tends to get stale often when depedent packages change
> > > or a new dependency is added that breaks the installation.
>
> @Abhilash: For non-Python programmers, it's not *that* hard, but there
> is a hurdle at the beginning.
So lift me up and throw me over that hurdle.
> I think the best thing to do is to advertise that we're always looking
> for doc contributions, and that if somebody's not familiar with reST,
> they shouldn't let that stop them. Of course we'll help them with
> markup, and if necessary we'll do it.
"Raises hand here"
--
Brian Carpenter
Harmonylists.com
Emwd.com
4 years, 4 months

[MM3-users] Re: Default values for lists in Mailman 3
by Markus Grandpré
Dear Mark, dear list,
in Menu "Mass Operations / Mass Subscription" I have set the default
value for checkbox "Invitation" in file
</usr/lib/python3/dist-packages/postorius/forms/list_forms.py> (on
Debian 12) as you had suggested:
invitation = forms.BooleanField(
label=_('Invitation'),
initial=True,
required=False,
help_text=_(
'If checked, the other checkboxes are ignored and the users
will '
'be sent an invitation to join the list and will be
subscribed '
'upon acceptance thereof.'
),
widget=forms.CheckboxInput(),
)
However, administrators of mailing lists on our Mailman3 demo system
report that the invitation is still sent, even if they have deactivated
the sending of the invitation via the “Invitation” checkbox.
What have I done wrong?
Best regards,
Markus
Am 20.09.24 um 09:05 schrieb Markus Grandpré:
> Thank you very much for your answer.
>
> Best regards,
> Markus
>
> Am 19.09.24 um 22:03 schrieb Mark Sapiro:
>> On 9/19/24 05:46, Markus Grandpré wrote:
>>> Dear list,
>>>
>>> I would like to activate the invitation setting for all lists as
>>> default. In Mailman 2.1 I have done this in the file </etc/mailman/
>>> mm_cfg.py>:
>>>
>>>
>>> DEFAULT_SUBSCRIBE_OR_INVITE = Yes
>>>
>>>
>>> How can I do this in Mailman 3?
>>
>> There is a draft merge request at https://gitlab.com/mailman/
>> postorius/-/merge_requests/930 which implements a framework for
>> setting Postorius defaults and creates a setting to set the default
>> for pre- verified on the mass subscription page. Once merged, this can
>> easily be extended to provide a default for Invitation.
>>
>> In the mean time, you can only do this by patching src/postorius/
>> forms/ list_forms.py like
>> ```
>> --- a/src/postorius/forms/list_forms.py
>> +++ b/src/postorius/forms/list_forms.py
>> @@ -1283,7 +1283,7 @@ class ListMassSubscription(forms.Form):
>>
>> invitation = forms.BooleanField(
>> label=_('Invitation'),
>> - initial=False,
>> + initial=True,
>> required=False,
>> help_text=_(
>> 'If checked, the other checkboxes are ignored and the
>> users will '
>> ```
>>> Can I also transfer other default values like:
>>>
>>> ...
>>> DEFAULT_SERVER_LANGUAGE = 'en'
>>> DEFAULT_SEND_REMINDERS = 1
>>> DEFAULT_SUBSCRIBE_OR_INVITE = Yes
>>> DEFAULT_PRIVATE_ROSTER = 2
>>> DEFAULT_ARCHIVE = Off
>>> DEFAULT_ARCHIVE_PRIVATE = 1
>>> ...
>>>
>>> from the very same configuration file to Mailman 3? Is there a
>>> documentation of the default values for lists in Mailman 3?
>>
>> This is done by creating a list style with the desired defaults. See
>> https://docs.mailman3.org/projects/mailman/en/latest/src/mailman/
>> styles/ docs/styles.html for documentation of styles and see https://
>> gitlab.com/ mailman/example-mailman-plugin for an example of creating
>> a plugin in Mailman core to make a persistent style.
>>
>> There is no specific doc for the list settings. You need to look at
>> https://gitlab.com/mailman/mailman/-/blob/master/src/mailman/styles/
>> base.py for the various settings and https://gitlab.com/mailman/
>> mailman/-/blob/master/src/mailman/styles/default.py to see which
>> default classes are applied for various styles.
>>
>
>
> _______________________________________________
> Mailman-users mailing list -- mailman-users(a)mailman3.org
> To unsubscribe send an email to mailman-users-leave(a)mailman3.org
> https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/
> Archived at: https://lists.mailman3.org/archives/list/mailman-users@mailman3.org/message…
>
> This message sent to markus.grandpre(a)uni-konstanz.de
--
Markus Ludwig Grandpré
Universität Konstanz
Kommunikations-, Informations-, Medienzentrum (KIM)
Abteilung IT-Dienste Forschung und Lehre,
B803, Tel: ++49 7531 88 4342
9 months

[MM3-users] Re: Fwd: Re: Removing a mail addresses and users
by Abhilash Raj
On Wed, Jun 10, 2020, at 3:33 PM, Allan Hansen wrote:
> All,
>
> This disconnect between Mailman Core and Django and Postorius is, by
> far, the weakest and, for subscribers, most confusing aspect of MM3
> (once it has been installed, which is extremely hard and confusing).
The disconnect was intentional to make sure that we are fully able to leverage the power of Django's ability to run multiple dis-connected applications in a single Site and Account system. And Mailman Core was intentionally designed to not be an account management system so it can be kept simple.
The disconnect however has caused more confusion than has helped, which we acknowledge. But this disconnect doesn't exist all that much right now, barring any bugs. We synchronize most of the state from Postorius down to Mailman Core including, any additional addresses that you add, primary address etc. Display Names don't trigger an update in Core, but it isn't that hard to do if you open a ticket.
>
> In a true account-centric system, you set up a web account and from
> there manage your emails and, for each email, your subscriptions.
> Subscription options would be hierarchical: account/email/list, with
> lower levels inheriting/overriding settings from/the level above.
You are able to sign in via web and manage your email and subscriptions. The preferences also work exactly how you described above where the lower level override the default and/or upper level settings.
>
> That’s really what I had expected when I pushed for us to move our 50
> email lists to MM3 and I was very excited about the prospect,
> as it would solve a lot of system/subscriber management issues I had
> managing MM2.
>
> Alas, I was very surprised that that’s not how MM3 works. Some things
> got harder, even, such as the inability to change subscription
> addresses, which should have been a showstopper from the start!
> I still hope that MMxx OOTB will get there, but I guess it’ll be along
> haul. Would we be talking about MM4 to be released 20 years from now?
As a Subscriber, you are able to do switch emails in subscriptions from your options page. The URL to which is displayed in the List's Summary page when you are logged in. Yes, it requires an approval if the list's settings are set to moderate but that is going to be fixed, see this issue[1]. It is quite simple IMO to fix this one, if someone wants to take this up.
[1]: https://gitlab.com/mailman/postorius/-/issues/425
Are you asking about switching emails as an administrator for your subscribers?
> Some dedicated and skilled developers are currently investing heavily
> in a replacement for Postorius, but I really believe that any work is
> better spent transforming Mailman Core etc. into a true account-based
> system. Then, and only then, will it make sense to build new and better
> interfaces on top, as, without a healthy core, such interface will
> currently may have to inherit the confusion and disconnect that
> currently is so aggravating.
I don't know if we want to add account management to Core, but User management is missing from Postorius, that is true. We punted on it and delegated that part to Django's admin interface. Long long time ago, I remember seeing that there was a User's tab for managing users, but that has since changed I think.
If you and some others on this list would like to propose an RFC here[2], it would be a great help for me. What I am basically looking for is what kind of "User management" are administrators looking for. It doesn't have to be too detailed but a single line example would be:
- As a Admin, I would like to delete a User completely from my system, including all their addresses and subscription
- Also, it would be good to delete their account but retain their subscriptions
- As a Admin, I would like to update User's attributes in the system like:
- Manually verify their email address
- Manually update their Name
- As a User, I would like to delete my own account and all the subscriptions.
Maybe this could be a starting point, but something like this can be added to Postorius.
[2]: https://gitlab.com/mailman/postorius/-/issues/new
As for the question in this thread, you are able to delete the User from Django's admin page and that would delete all the related EmailAddress for them. Deleting an Email address doesn't delete the User, since the relationship exists that User owns Emails. There is currently no way to delete all the subscriptions for a User though.
> The above is not meant to aggravate the MM3 development team, for which
> I have utmost respect and gratitude, and which I admire for their
> tireless support given over decades to the community of admins.
> Software development is devilishly hard and time consuming.
And thank you for posting what you think is an important enhancement to Postorius. We don't have a very strict process to choose what new features to work on, so email like this do help us prioritize. Other users could also help by upvoting or just adding "+1" to the bugs/feature enhancements that affects them the most so we can fix them sooner rather than later. I would be more than happy if more people participated in just being able to prioritize features, all the work really happens in the open on Gitlab.
As administrators of some 'open source' lists, the needs of us as admins are somewhat different from what would be in a closed organization and ability to kick someone completely out of the system is something never I had to do since folks are supposed to manage their own subscriptions. We do ban people from sending emails if they've been spamming, but that is a different thing, they are still able to login into Postorius AFAIK.
> Yours,
>
> Allan Hansen
> hansen(a)rc.org
>
>
>
>
> > Begin forwarded message:
> >
> > From: Mark Sapiro <mark(a)msapiro.net>
> > Subject: [MM3-users] Re: Removing a mail addresses and users
> > Date: June 10, 2020 at 12:46:01 PDT
> > To: mailman-users(a)mailman3.org
> >
> > On 6/10/20 10:23 AM, Abhijith PA via Mailman-users wrote:
> >> Hello.
> >>
> >> I tried to remove random email address signing ups (which I signed up
> >> while testing) via admin panel. After removing I tried to sign up again,
> >> but I am getting,
> >>
> >> 'A user is already registered with this e-mail address'
> >
> > You removed the user's subscription from the list, but you didn't remove
> > the user from the system.
> >
> > Mailman3 has a concept of `user` which didn't exist in Mailman 2.1.
> > User's have addresses and a user or one of the user's addresses can
> > belong to a list with one or more roles (non-member, member, moderator
> > or owner)
> >
> >
> >> Combing through the database, I found auth_user table in mailman3web db
> >> still contain those mail address. How to wipe email address entirely
> >> from the db so I can signup again without the 'forget password' method
> >
> > There are a couple of things. If you log in to the web UI as a django
> > superuser, you can go to the django admin UI -> Users section and delete
> > the User, but I think that will only delete the web user and not delete
> > the user from Mailman core.
> >
> > You can also log in to the web UI as the user and go to
> > <https://lists.mailman3.org/user-profile/delete>, but that again only
> > deletes the web user, and if you could do that, you could just subscribe
> > once you're logged in, so I assume that's what you want to avoid.
> >
> > I don't think there is a way for a user as opposed to a site admin to
> > delete her user record from Mailman core and even for a site admin,
> > there's no way in Postorius to delete a user from core. It has to be
> > done via REST
> > <https://docs.mailman3.org/projects/mailman/en/latest/src/mailman/rest/docs/…>
> > or `mailman shell`.
> >
> > --
> > Mark Sapiro <mark(a)msapiro.net> The highway is for gamblers,
> > San Francisco Bay Area, California better use your sense - B. Dylan
> > _______________________________________________
> > Mailman-users mailing list -- mailman-users(a)mailman3.org
> > To unsubscribe send an email to mailman-users-leave(a)mailman3.org
> > https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/
>
> _______________________________________________
> Mailman-users mailing list -- mailman-users(a)mailman3.org
> To unsubscribe send an email to mailman-users-leave(a)mailman3.org
> https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/
>
--
thanks,
Abhilash Raj (maxking)
5 years

[MM3-users] Re: No e-mail distribution after import of archive
by Markus Grandpré
Dear Mr Odhiambo,
thank you very much for your reply.
In mailman.log I see:
Nov 12 09:46:02 2024 (698086) ACCEPT:
<d6723f50-7ca8-4ba9-85ef-bb5575dacd75(a)uni-konstanz.de>
[12/Nov/2024:09:46:03 +0100] "GET
/3.1/lists/import_mm3_testliste(a)mailman-test.uni-konstanz.de HTTP/1.1"
200 486 "-" "GNU Mailman REST client v3.3.5"
[12/Nov/2024:09:46:03 +0100] "GET
/3.1/lists/import_mm3_testliste(a)mailman-test.uni-konstanz.de/config
HTTP/1.1" 200 3446 "-" "GNU Mailman REST client v3.3.5"
[12/Nov/2024:09:46:03 +0100] "GET
/3.1/users/markus.grandpre(a)uni-konstanz.de HTTP/1.1" 200 285 "-" "GNU
Mailman REST client v3.3.5"
[12/Nov/2024:09:46:03 +0100] "GET
/3.1/lists/import_mm3_testliste.mailman-test.uni-konstanz.de/roster/owner
HTTP/1.1" 200 789 "-" "GNU Mailman REST client v3.3.5"
[12/Nov/2024:09:46:03 +0100] "GET
/3.1/addresses/markus.grandpre(a)uni-konstanz.de HTTP/1.1" 200 436 "-"
"GNU Mailman REST client v3.3.5"
[12/Nov/2024:09:46:03 +0100] "GET
/3.1/lists/import_mm3_testliste.mailman-test.uni-konstanz.de/roster/moderator
HTTP/1.1" 200 90 "-" "GNU Mailman REST client v3.3.5"
Nov 12 09:46:03 2024 (698083) HyperKitty archived message
<d6723f50-7ca8-4ba9-85ef-bb5575dacd75(a)uni-konstanz.de> to
https://mailman-test.uni-konstanz.de/mailman3/hyperkitty/list/import_mm3_te…
In smtp.log I found:
Nov 12 09:46:02 2024 (698087) Available AUTH mechanisms: LOGIN(builtin)
PLAIN(builtin)
Nov 12 09:46:02 2024 (698087) Peer: ('127.0.0.1', 57230)
Nov 12 09:46:02 2024 (698087) ('127.0.0.1', 57230) handling connection
Nov 12 09:46:02 2024 (698087) ('127.0.0.1', 57230) >> b'LHLO
mailman-app-test.kim.uni-konstanz.de'
Nov 12 09:46:02 2024 (698087) ('127.0.0.1', 57230) >> b'MAIL
FROM:<markus.grandpre(a)uni-konstanz.de> SIZE=9649 BODY=8BITMIME'
Nov 12 09:46:02 2024 (698087) ('127.0.0.1', 57230) sender:
markus.grandpre(a)uni-konstanz.de
Nov 12 09:46:02 2024 (698087) ('127.0.0.1', 57230) >> b'RCPT
TO:<Import_mm3_testliste(a)mailman-test.uni-konstanz.de>'
Nov 12 09:46:02 2024 (698087) ('127.0.0.1', 57230) recip:
Import_mm3_testliste(a)mailman-test.uni-konstanz.de
Nov 12 09:46:02 2024 (698087) ('127.0.0.1', 57230) >> b'DATA'
Nov 12 09:46:02 2024 (698087) ('127.0.0.1', 57230) >> b'QUIT'
Nov 12 09:46:02 2024 (698087) ('127.0.0.1', 57230) connection lost
Nov 12 09:46:02 2024 (698087) ('127.0.0.1', 57230) Connection lost
during _handle_client()
I have no idea why there is a "connection lost". What do you think? How
can I increase the log level?
With kind regards,
Markus
Am 12.11.24 um 09:38 schrieb Odhiambo Washington:
> On Tue, Nov 12, 2024 at 10:34 AM Markus Grandpré <
> markus.grandpre(a)uni-konstanz.de> wrote:
>
>> Dear Mr. Sapiro,
>>
>> on our test system we noticed the problem that after importing a mailing
>> list archive from a Mailman system v2.1 into a Mailman system v3.3.8,
>> e-mails are no longer distributed via this mailing list. E-mails that
>> are written to the list find their way into the archive, but they are
>> not sent to any member of the list.
>>
>> Before the archive was imported, writing an e-mail to the list and
>> distributing this e-mail via the list was not a problem. Unfortunately,
>> we cannot find any indication of this issue in the log of the mailman
>> system v3.3.8. Please help us to further analyze and solve this problem,
>> as we are planning to import 188 archives into our new productive
>> mailman system v3.3.8 during the next months.
>>
>
> Archives are imported into HyperKitty and should not in any way interfere
> with Mailman Core.
> From what I learnt recently, you can even import an archive into HyperKitty
> without having a ML in Core associated with it.
> So my starting point would be to look at mailman.log and see what goes in
> there. I could even up the debugging level if need be.
> For now, is there anything abnormal in mailman.log or smtp.log?
>
>
>
>
--
Markus Ludwig Grandpré
Universität Konstanz
Kommunikations-, Informations-, Medienzentrum (KIM)
Abteilung IT-Dienste Forschung und Lehre,
B803, Tel: ++49 7531 88 4342
7 months, 2 weeks

[MM3-users] Re: share directories between postfix and mailman 3
by Thomas Schachtner
Mark Sapiro wrote:
> On 1/22/24 13:05, Thomas Schachtner via Mailman-users wrote:
>> Hi there,
>>
>> But that's not the full deal. Postfix needs access to some hashed
>> configuration files containing the transport maps and the domains of
>> the mailman installation, and mailman needs the contents of the
>> postfix configuration file.
>
> Why do you think Mailman needs the contents of the postfix
> configuration file.. I don't think so.
I thought so, as mailman does not start if there's not
/etc/postfix/main.cf file is there.
The following messages are logged:
Jan 23 21:20:35 mailman mailman3[491404]: RuntimeError: command failure:
/usr/sbin/postmap /var/lib/mailman3/data/postfix_lmtp, 1, Operation not
permitted
Jan 23 21:20:35 mailman mailman3[491404]: command failure:
/usr/sbin/postmap /var/lib/mailman3/data/postfix_domains, 1, Operation
not permitted
If /etc/postfix/main.cf is there, mailman is starting perfectly fine.
But in another anwer I learned that mailman might not need the contents
of that file but rather change it (although I did not see any changes).
>
>> As a quick and dirty solution, I've established a process which
>> periodically copies the /var/lib/mailman3 directory from the mailman
>> box to the postfix box using rsync.
>
> It appears you are using the Debian/Ubuntu package or at least have
> configured `layout: fhs` in the `[mailman]` section of mailman.cfg.
> This is OK, but in any case, all Postfix needs is
> /var/lib/mailman3/data/*.
Thanks for this information. I already thought so, but I was not sure.
Yes, I am using the Debian package.
I also found the line with 'layout', but it reads 'layout: debian'. They
write: "You should not change this variable"
>
>> But I would like to have a more professional solution, like a
>> directly shared directory between both.
>> I did not yet find any suggestions on how to achieve this. Are there
>> any best practices recommendations?
>> I already tried sharing the directories using sshfs, but that did not
>> work.
>>
>> I connected the remote directory
>> postfix.example.com:/var/lib/mailman3 to my local directory
>> /var/lib/mailman3 using
>>
>> sshfs root@postfix.example.com:/var/lib/mailman3 /var/lib/mailman3
>
>
> I would suggest the opposite. I.e. on the postfix machine
> ```
> sshfs user@mailman_machine:/var/lib/mailman3/data /var/lib/mailman3/data
> ```
There are two reasons why I would like to do it the other way around:
(1) I would like to make all changes on the mailman3 box and change as
little as possible on the postfix server and
(2) mailman is running on a system which does not have a fixed IP
address. Mounting the file system from there can become complicated, as
the IP address can change on a daily basis...
>> This seemed to work pretty fine, as all files and directories seemed
>> to be available, but when starting mailman 3, the following error
>> message was shown:
>> FileExistsError: A race condition might have happened.
>> /var/lib/mailman3 actually exists and is not a directory.
>>
>> Any idea why this message is shown?
>
> Possibly because the uid and gid of /var/lib/mailman3 on the postfix
> machine do not map to the appropriate Mailman uid and gid on the
> mailman machine.
You refer to the uid and gid of the "list" user? They are both 38 (uid
and gid) on both machines.
>
>> So, is it a bad idea to use sshfs?
>
>
> If you do it the other way, it might work.
>
I try to work around the changing IP address challenge then.
Thanks!
Tom
1 year, 5 months

[MM3-users] Re: mm3 installation question
by Odhiambo Washington
On Wed, Mar 6, 2024 at 8:53 PM Mark Sapiro <mark(a)msapiro.net> wrote:
> On 3/6/24 1:33 AM, Odhiambo Washington wrote:
> > On Wed, Mar 6, 2024 at 12:13 PM Stephen J. Turnbull <
> > turnbull.stephen.fw(a)u.tsukuba.ac.jp> wrote:
> >
> >> Odhiambo Washington writes:
> >>
> >> > The odd thing is that the HOWTO that he followed never involves the
> >> > manipulation of any urls.py at all - it's not even mentioned at any
> >> > point. So obviously the issue is caused by something else and I
> >> > suspect something within Apache needs to be re-evaluated in the
> >> > guide.
>
>
> The HOWTO installs mailman-web which contains a urls.py.
>
> >>
> >> Note that Apache doesn't know about the "/postorius" and "/hyperkitty"
> >> URI paths. It is quite unclear to me how this works at all with
> >> either the
> >>
> >> path('mailman3/', include('postorius.urls')),
> >> path('archives/', include('hyperkitty.urls')),
> >> path('postorius/', include('postorius.urls')),
> >> path('hyperkitty/', include('hyperkitty.urls')),
> >>
> >> version of urls.py or the reverse order version
> >>
> >> path('postorius/', include('postorius.urls')),
> >> path('hyperkitty/', include('hyperkitty.urls')),
> >> path('mailman3/', include('postorius.urls')),
> >> path('archives/', include('hyperkitty.urls')),
>
>
> This is an issue with Django. I'm not sure of the exact mechanism, but
> consider the first of the above two sets. If you go to the mailman3/ URL
> that gets redirected to the postorius/ URL. I.e. two paths that
> ultimately reference the same thing wind up considering the second path
> as the canonical path and redirecting the first path to the second.
>
> I was not initially aware of this when I added the postorius/ and
> hyperkitty/ paths to mailman_web/urls.py. I did this with the intent of
> making either set of paths work, and I added those paths after the
> mailman3/ and archives/ paths, and this version got released as
> mailman-web 0.0.8. That caused the recommended Apache config to fail
> because now the mailman3/ and archives/ paths were redirected to the
> postorius/ and hyperkitty/ URLs which are not in the recommended Apache
> config.
>
> I have since reordered the paths in mailman_web/urls.py, but that
> version isn't yet released. Thus the issue. See
>
> https://lists.mailman3.org/archives/list/mailman-users@mailman3.org/message…
> for some background.
>
>
> > My thinking then is that the documentation at
> >
> https://docs.list.org/en/latest/install/virtualenv.html#apache-configuration
> > needs to be fixed by adding the missing bits,
>
>
> What needs to be done is a mailmab-web 0.0.9 release in PyPI. This will
> fix the issue.
>
Hi Mark,
Thank you for making it much clearer.
Is it possible that an Apache directive like below will fix everything
(albeit discreetly with sysadmins driving blindly)?
ProxyPass "/" "http://127.0.0.1:8000/"
As was suggested by Mr. Turnbull (and previously by you on another thread)?
It will be simpler, but leaves almost everyone (except the Devs) blind to
the fact there exists a urls.py somewhere that determines the mappings?
Maybe a note about it in the documentation will help?
--
Best regards,
Odhiambo WASHINGTON,
Nairobi,KE
+254 7 3200 0004/+254 7 2274 3223
In an Internet failure case, the #1 suspect is a constant: DNS.
"Oh, the cruft.", egrep -v '^$|^.*#' ¯\_(ツ)_/¯ :-)
[How to ask smart questions:
http://www.catb.org/~esr/faqs/smart-questions.html]
1 year, 3 months

[MM3-users] Re: django-allauth failures, but only for some users (independent of browser?)
by Jered Floyd
I'm able to reproduce this and will look into it -- what version of django-allauth are you using? (And what is the expected behavior for that endpoint?)
--Jered
----- On Dec 6, 2023, at 7:57 PM, Mark Sapiro mark(a)msapiro.net wrote:
> On 12/6/23 14:49, Jered Floyd wrote:
>>
>> The difference in behavior was using social login buttons for an existing
>> account vs. creating a new account.
>>
>> This is another damn django-allauth regression, starting in 0.57.0. It seem to
>> be this commit that is to blame:
>> https://github.com/pennersr/django-allauth/commit/be779dfee5a328a3a42edc2c9…
>>
>> In allauth/socialaccount/models.py:lookup(self):285 there is an attempt to look
>> up the social account as one that already exists. If that fails, this commit
>> calls self.account.get_provider() without passing the request object, which
>> leads to the eventual error.
>>
>> I believe this is a django-allauth bug, and have submitted a pull request to fix
>> it here:
>> https://github.com/pennersr/django-allauth/pull/3548
>
> Thanks for all your work on this. It is much appreciated. However, your
> patch doesn't fix my issue with the URL
> https://example.com/accounts/social/connections/ which still produces
> the following:
> ```
> ERROR 2023-12-07 00:05:55,032 169452 django.request Internal Server
> Error: /accounts/social/connections/
> Traceback (most recent call last):
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/core/handlers/exception.py",
> line 55, in inner
> response = get_response(request)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/core/handlers/base.py",
> line 220, in _get_response
> response = response.render()
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/response.py",
> line 114, in render
> self.content = self.rendered_content
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/response.py",
> line 92, in rendered_content
> return template.render(context, self._request)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/backends/django.py",
> line 61, in render
> return self.template.render(context)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 175, in render
> return self._render(context)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 167, in _render
> return self.nodelist.render(context)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 1005, in render
> return SafeString("".join([node.render_annotated(context) for node
> in self]))
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 1005, in <listcomp>
> return SafeString("".join([node.render_annotated(context) for node
> in self]))
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 966, in render_annotated
> return self.render(context)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/loader_tags.py",
> line 157, in render
> return compiled_parent._render(context)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 167, in _render
> return self.nodelist.render(context)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 1005, in render
> return SafeString("".join([node.render_annotated(context) for node
> in self]))
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 1005, in <listcomp>
> return SafeString("".join([node.render_annotated(context) for node
> in self]))
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 966, in render_annotated
> return self.render(context)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/loader_tags.py",
> line 157, in render
> return compiled_parent._render(context)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 167, in _render
> return self.nodelist.render(context)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 1005, in render
> return SafeString("".join([node.render_annotated(context) for node
> in self]))
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 1005, in <listcomp>
> return SafeString("".join([node.render_annotated(context) for node
> in self]))
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 966, in render_annotated
> return self.render(context)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/loader_tags.py",
> line 157, in render
> return compiled_parent._render(context)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 167, in _render
> return self.nodelist.render(context)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 1005, in render
> return SafeString("".join([node.render_annotated(context) for node
> in self]))
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 1005, in <listcomp>
> return SafeString("".join([node.render_annotated(context) for node
> in self]))
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 966, in render_annotated
> return self.render(context)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/loader_tags.py",
> line 63, in render
> result = block.nodelist.render(context)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 1005, in render
> return SafeString("".join([node.render_annotated(context) for node
> in self]))
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 1005, in <listcomp>
> return SafeString("".join([node.render_annotated(context) for node
> in self]))
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 966, in render_annotated
> return self.render(context)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/loader_tags.py",
> line 63, in render
> result = block.nodelist.render(context)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 1005, in render
> return SafeString("".join([node.render_annotated(context) for node
> in self]))
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 1005, in <listcomp>
> return SafeString("".join([node.render_annotated(context) for node
> in self]))
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 966, in render_annotated
> return self.render(context)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/defaulttags.py",
> line 321, in render
> return nodelist.render(context)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 1005, in render
> return SafeString("".join([node.render_annotated(context) for node
> in self]))
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 1005, in <listcomp>
> return SafeString("".join([node.render_annotated(context) for node
> in self]))
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 966, in render_annotated
> return self.render(context)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/defaulttags.py",
> line 238, in render
> nodelist.append(node.render_annotated(context))
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 966, in render_annotated
> return self.render(context)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/defaulttags.py",
> line 539, in render
> values = {key: val.resolve(context) for key, val in
> self.extra_context.items()}
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/defaulttags.py",
> line 539, in <dictcomp>
> values = {key: val.resolve(context) for key, val in
> self.extra_context.items()}
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 715, in resolve
> obj = self.var.resolve(context)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 847, in resolve
> value = self._resolve_lookup(context)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 914, in _resolve_lookup
> current = current()
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/allauth/socialaccount/models.py",
> line 147, in get_provider_account
> return self.get_provider().wrap_account(self)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/allauth/socialaccount/models.py",
> line 141, in get_provider
> provider = self._provider = adapter.get_provider(
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/allauth/socialaccount/adapter.py",
> line 204, in get_provider
> app = self.get_app(request, provider=provider)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/allauth/socialaccount/adapter.py",
> line 284, in get_app
> apps = self.list_apps(request, provider=provider, client_id=client_id)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/allauth/socialaccount/adapter.py",
> line 231, in list_apps
> db_apps = SocialApp.objects.on_site(request)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/allauth/socialaccount/models.py",
> line 27, in on_site
> site = get_current_site(request)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/contrib/sites/shortcuts.py",
> line 16, in get_current_site
> return Site.objects.get_current(request)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/contrib/sites/models.py",
> line 63, in get_current
> raise ImproperlyConfigured(
> django.core.exceptions.ImproperlyConfigured: You're using the Django
> "sites framework" without having set the SITE_ID setting. Create a site
> in your database and set the SITE_ID setting or pass a request to
> Site.objects.get_current() to fix this error.
> ```
>
> --
> Mark Sapiro <mark(a)msapiro.net> The highway is for gamblers,
> San Francisco Bay Area, California better use your sense - B. Dylan
>
> _______________________________________________
> Mailman-users mailing list -- mailman-users(a)mailman3.org
> To unsubscribe send an email to mailman-users-leave(a)mailman3.org
> https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/
> Archived at:
> https://lists.mailman3.org/archives/list/mailman-users@mailman3.org/message…
>
> This message sent to jered(a)convivian.com
1 year, 6 months

[MM3-users] Re: Confirmation emails to Users has wrong domain name (example.com!)
by Abhilash Raj
On Thu, Sep 30, 2021, at 2:20 AM, Odhiambo Washington wrote:
> On Thu, Sep 30, 2021 at 1:59 AM Abhilash Raj <maxking(a)asynchronous.in>
> wrote:
>
>>
>>
>> > On Sep 29, 2021, at 2:34 PM, Odhiambo Washington <odhiambo(a)gmail.com>
>> wrote:
>> >
>> > On Wed, Sep 29, 2021 at 8:31 PM Mark Sapiro <mark(a)msapiro.net> wrote:
>> >
>> >> On 9/29/21 9:50 AM, Odhiambo Washington wrote:
>> >>> 1. Confirmation emails to Users has wrong domain name (example.com!)
>> >>> <https://docs.mailman3.org/en/latest/faq.html#id1>
>> >>> <
>> >>
>> https://docs.mailman3.org/en/latest/faq.html#confirmation-emails-to-users-h…
>> >>>
>> >>>
>> >>> This happens when your reverse (SSL) proxy isn’t setting up the correct
>> >>> headers when proxying requests. Fix this by setting the right
>> >>> proxy_set_header directives:
>> >> ...
>> >>> How is this supposed to be mitigated in Apache when using WSGI?
>> >>>
>> >>> My config:
>> >>>
>> >>> WSGIDaemonProcess hyperkitty threads=25 python-path=/usr/local/mailman
>> >>> user=mailman group=mailman
>> >>> WSGIPythonHome "/usr/local"
>> >>> WSGIProcessGroup hyperkitty
>> >>
>> >>
>> >> You are using mod_wsgi and not proxying at all, so this is not relevant
>> >> in your case.
>> >>
>> >> Are you actually seeing this issue? If so, it might be related to
>> >>
>> >>
>> https://docs.mailman3.org/en/latest/faq.html#the-domain-name-displayed-in-h…
>> >>
>> >
>> > My issue is related to this, but the documentation referred to is not for
>> > the faint-hearted!
>> > I can't make head or tails of it.
>>
>> Click on “Domain” in Postorius from the top bar, which should take you to
>> the Domains page.
>>
>> For your domain (in the “Mail Host” column), see the corresponding “Web
>> Host” column, it should look something like:
>>
>> lists.mailman3.org (lists.mailman3.org)
>> (Edit)
>> SITE_ID = 1
>>
>
> Mine looks different, slightly. But there is no example.com at all.
>
> [image: Abhilash.png]
>
>
>
>>
>> on a new-ish version of Postorius.
>>
>
> I have the newest versions of everything, having installed only yesterday.
>
>
>>
>> If it doesn’t show the right values and instead shows “example.com” for
>> you, click on the “Edit” link, which will take
>> you to a page that will allow you to edit both the values.
>>
>
> It shows the right values, but with "SITE_ID = 2". In my settings_local.py
> I have SITE_ID = 1.
> I suppose the example.com is the one tied to SITE_ID = 1 and that is what I
> have in my settings_local.py.
That is most likely what is happening.
> Should I edit my settings_local.py?
Yes, please update it to have SITE_ID = 2 to correspond to the site you want and restart.
>
> I am still confused.
>
> --
> Best regards,
> Odhiambo WASHINGTON,
> Nairobi,KE
> +254 7 3200 0004/+254 7 2274 3223
> "Oh, the cruft.", egrep -v '^$|^.*#' :-)
> _______________________________________________
> Mailman-users mailing list -- mailman-users(a)mailman3.org
> To unsubscribe send an email to mailman-users-leave(a)mailman3.org
> https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/
--
thanks,
Abhilash Raj (maxking)
3 years, 9 months

[MM3-users] Re: Bulk changes to delivery mode and moderation action
by David Newman
On 1/7/22 12:06 PM, Mark Sapiro wrote:
> On 1/7/22 11:06 AM, David Newman wrote:
>>
>> 1. In Users/Members, moderation action for the newly resubscribed
>> users shows as "None". Is there a method, either in the UI or the
>> command line, to change this to "Default processing" for all users?
>
>
> I assume you don't want to set `Default action to take when a member
> posts to the list` to Default Processing because you want new member
> posts to be held. This is a good practice. To set all members to default
> processing in mailman shell
..
OK, thanks
>> 2. Although Delivery Mode shows as "Regular" for all users in
>> Users/Members list, clicking on a member's name shows all options such
>> as delivery status, delivery mode, etc., as undefined.
>
>
> They show as undefined, but if you look at your own settings by
> selecting `Mailman settings` from the dropdown under your username at
> the upper right in Postorius, you will see you have Global Mailman
> preferences, Address-based preferences and List-based preferences. If a
> list based preference is unset for a list, it falls back to the address
> based preference for the address and if that's unset, to the global
> preference.
>
> When you as an admin look at a user, you only see the user's list based
> preferences.
Thanks. This makes sense, but something's wrong with this particular list.
I was able to change preferences using the shell commands you kindly
provided. All list member now have regular delivery and default moderation.
However, there's no evidence test messages to the list are going out.
(Nondelivery was the reason I was mucking around in the admin panel in
the first place.)
The Postfix log shows delivery to the list address.
MM3's smtp.log shows the usual handshake.
However, I do not then see messages going out to subscribers in the
Postfix log, and as one of those subscribers I do not receive a copy
even though my preferences are set to receive my own posts.
The admin panel shows 0 messages held for moderation.
Another mailing list in the same domain on the same server delivers mail
to all subscribers OK.
This is surely config problem on my end, but which log(s) and/or admin
panel setting(s) to check?
Thanks again.
dn
>
>> Similar question: How to set subscriber options for all members in one
>> go?
>
>
> Per the above, you only need to set the user's preferences if they don't
> have address based preferences and the preference differs from the
> global (default) preferences.
>
> However, if you want to set the member's list preferences, you could add
> to the beginning of the above:
> ```
> >>> from mailman.interfaces.member import DeliveryMode, DeliveryStatus
> >>> english = getUtility(ILanguageManager).get('en')
> ```
> and to the `for` loop in the above:
> ```
> ... mbr.preferences.acknowledge_posts = False
> ... mbr.preferences.delivery_mode = DeliveryMode.regular
> ... mbr.preferences.delivery_status = DeliveryStatus.enabled
> ... mbr.preferences.hide_address = False
> ... mbr.preferences.preferred_language = english
> ... mbr.preferences.receive_list_copy = False
> ... mbr.preferences.receive_own_postings = True
> ```
> Or whatever you think these settings should be.
>
>> 3. As a subscriber to this list, I received email notification that
>> I'd been unsubscribed. Where is the control for enabling/disabling
>> subscription notifications?
>
>
> Settings -> Automatic Responses
>
>
>> Settings/Member Policy/Un-subscription Policy is set to Confirm, but I
>> don't think that's relevant here since I unsubscribed users as the
>> Django superuser.
>
>
> Correct.
>
3 years, 5 months

[MM3-users] SOLVED (was: compress failed...)
by Guillermo Hernandez (Oldno7)
El 30/10/22 a las 12:22, Guillermo Hernandez (Oldno7) via Mailman-users
escribió:
>
> El 28/10/22 a las 9:18, Guillermo Hernandez (Oldno7) via Mailman-users
> escribió:
>>
>> El 27/10/22 a las 21:39, Mark Sapiro escribió:
>>>> After that the compress part showed errors... but the postorius web
>>>> maintenance was working well except for the CSRF error
>>>> verification. I will trace the compress errors and will try to find
>>>> the problem later.
>>>
>>>
>>> Do you have `COMPRESS_ENABLED = True` in your settings? If that's
>>> not the issue, it may be in the settings for COMPRESS_PRECOMPILERS
>>
>> While I'm tracing the problem out, this is the configuration I had
>> working and the error it shows after upgrade:
>>
>> <------- snip of settings.py>
>>
>> #
>> COMPRESS_PRECOMPILERS = (
>> ('text/less', 'lessc {infile} {outfile}'),
>> ('text/x-scss', 'sassc -t compressed {infile} {outfile}'),
>> ('text/x-sass', 'sassc -t compressed {infile} {outfile}'),
>> )
>> # On a production setup, setting COMPRESS_OFFLINE to True will bring a
>> # significant performance improvement, as CSS files will not need to be
>> # recompiled on each requests. It means running an additional "compress"
>> # management command after each code upgrade.
>> #
>> http://django-compressor.readthedocs.io/en/latest/usage/#offline-compression
>> #### activo compresion 18/12/20
>> COMPRESS_OFFLINE = True
>> ###COMPRESS_OFFLINE = False
>> <---------- end snip>
>>
>> And below is the error it shows:
>>
>> /usr/local/mailman3 # su -m mailman3 -c "python3 manage.py compress"
>> Traceback (most recent call last):
>> File "/usr/local/mailman3/manage.py", line 10, in <module>
>> execute_from_command_line(sys.argv)
>> File
>> "/usr/local/lib/python3.9/site-packages/django/core/management/__init__.py",
>> line 446, in execute_from_command_line
>> utility.execute()
>> File
>> "/usr/local/lib/python3.9/site-packages/django/core/management/__init__.py",
>> line 440, in execute
>> self.fetch_command(subcommand).run_from_argv(self.argv)
>> File
>> "/usr/local/lib/python3.9/site-packages/django/core/management/__init__.py",
>> line 279, in fetch_command
>> klass = load_command_class(app_name, subcommand)
>> File
>> "/usr/local/lib/python3.9/site-packages/django/core/management/__init__.py",
>> line 49, in load_command_class
>> return module.Command()
>> File
>> "/usr/local/lib/python3.9/site-packages/django/core/management/base.py",
>> line 274, in __init__
>> raise TypeError("requires_system_checks must be a list or tuple.")
>> TypeError: requires_system_checks must be a list or tuple.
>>
>>
> After searching around, I've got a hint of what can be happening. It
> seems a variable has changed in Django 4.1 its nature from boolean to
> a tuple
>
> https://github.com/painless-software/django-probes/issues/24
>
> I've upgraded another server with mailman3 lists, with the same config
> listed above, and it shows the same error in the "compress" part. I'm
> not sure where to set the requires_system_checks variable as in one of
> the comments of the link, and as it doesn't seems to break anything
> more, I will wait for more info before trying to avoid it. I'm sure it
> will have some repercusion on the performance, but I'll have to live
> with it.
>
>
> Thanks again for your supporting advices.
I did a
pip install --upgrade --force-reinstall Django==4.0.8
downgrading Django from 4.1 and now a
su -m mailman3 -c "python3 manage.py compress"
worked without pain.
>
>>
>>
>>
>>
>>
--
___________________________________________
Mailman's content filtering has removed the
following MIME parts from this message.
Content-Type: image/png
Name: firma-GHP-emails.png
Replaced multipart/alternative part with first alternative.
2 years, 8 months

[MM3-users] Re: Clearing webserver cache - Nginx
by Odhiambo Washington
On Tue, Aug 6, 2024 at 7:18 PM Mark Sapiro <mark(a)msapiro.net> wrote:
> On 8/6/24 00:24, Odhiambo Washington via Mailman-users wrote:
> >
> > In any case, here is my virtualhost config:
>
> It looks OK.
>
> I suggest you run
>
> mailman-web collectstatic --clear
> mailman-web compress
>
Done.
However, I still see the errors in Nginx logs:
```
root@eu:~# tail -f /var/log/nginx/mm3-lists_error.log
2024/08/06 18:52:54 [error] 37221#37221: *53355 open()
"/opt/mailman/mm/static/CACHE/css/output.158acc288604.css" failed (2: No
such file or directory), client: 108.162.238.164, server:
mm3-lists.kictanet.or.ke, request: "GET
/static/CACHE/css/output.158acc288604.css HTTP/2.0", host: "
mm3-lists.kictanet.or.ke", referrer: "
https://mm3-lists.kictanet.or.ke/archives/list/kictanet@lists.kictanet.or.k…
"
2024/08/06 19:11:24 [error] 37221#37221: *54872 open()
"/opt/mailman/mm/static/CACHE/css/output.6dab123e4897.css" failed (2: No
such file or directory), client: 162.158.170.169, server:
mm3-lists.kictanet.or.ke, request: "GET
/static/CACHE/css/output.6dab123e4897.css HTTP/2.0", host: "
mm3-lists.kictanet.or.ke", referrer: "
https://mm3-lists.kictanet.or.ke/archives/list/kictanet@lists.kictanet.or.k…
"
2024/08/06 19:11:24 [error] 37224#37224: *54875 open()
"/opt/mailman/mm/static/CACHE/css/output.158acc288604.css" failed (2: No
such file or directory), client: 162.158.171.16, server:
mm3-lists.kictanet.or.ke, request: "GET
/static/CACHE/css/output.158acc288604.css HTTP/2.0", host: "
mm3-lists.kictanet.or.ke", referrer: "
https://mm3-lists.kictanet.or.ke/archives/list/kictanet@lists.kictanet.or.k…
"
2024/08/06 19:12:27 [error] 37228#37228: *54974 open()
"/opt/mailman/mm/static/CACHE/css/output.6dab123e4897.css" failed (2: No
such file or directory), client: 162.158.106.81, server:
mm3-lists.kictanet.or.ke, request: "GET
/static/CACHE/css/output.6dab123e4897.css HTTP/2.0", host: "
mm3-lists.kictanet.or.ke", referrer: "
https://mm3-lists.kictanet.or.ke/archives/list/kictanet@lists.kictanet.or.k…
"
2024/08/06 19:12:27 [error] 37228#37228: *54975 open()
"/opt/mailman/mm/static/CACHE/css/output.158acc288604.css" failed (2: No
such file or directory), client: 162.158.106.14, server:
mm3-lists.kictanet.or.ke, request: "GET
/static/CACHE/css/output.158acc288604.css HTTP/2.0", host: "
mm3-lists.kictanet.or.ke", referrer: "
https://mm3-lists.kictanet.or.ke/archives/list/kictanet@lists.kictanet.or.k…
"
2024/08/06 19:27:27 [error] 37228#37228: *56500 open()
"/opt/mailman/mm/static/CACHE/css/output.6dab123e4897.css" failed (2: No
such file or directory), client: 172.70.188.20, server:
mm3-lists.kictanet.or.ke, request: "GET
/static/CACHE/css/output.6dab123e4897.css HTTP/2.0", host: "
mm3-lists.kictanet.or.ke", referrer: "
https://mm3-lists.kictanet.or.ke/archives/"
2024/08/06 19:27:27 [error] 37228#37228: *56501 open()
"/opt/mailman/mm/static/CACHE/css/output.158acc288604.css" failed (2: No
such file or directory), client: 172.70.188.84, server:
mm3-lists.kictanet.or.ke, request: "GET
/static/CACHE/css/output.158acc288604.css HTTP/2.0", host: "
mm3-lists.kictanet.or.ke", referrer: "
https://mm3-lists.kictanet.or.ke/archives/"
2024/08/06 19:29:18 [error] 37221#37221: *56722 open()
"/opt/mailman/mm/static/CACHE/css/output.6dab123e4897.css" failed (2: No
such file or directory), client: 172.68.1.156, server:
mm3-lists.kictanet.or.ke, request: "GET
/static/CACHE/css/output.6dab123e4897.css HTTP/2.0", host: "
mm3-lists.kictanet.or.ke", referrer: "
https://mm3-lists.kictanet.or.ke/archives/"
2024/08/06 19:29:18 [error] 37224#37224: *56724 open()
"/opt/mailman/mm/static/CACHE/css/output.158acc288604.css" failed (2: No
such file or directory), client: 172.68.3.81, server:
mm3-lists.kictanet.or.ke, request: "GET
/static/CACHE/css/output.158acc288604.css HTTP/2.0", host: "
mm3-lists.kictanet.or.ke", referrer: "
https://mm3-lists.kictanet.or.ke/archives/"
2024/08/06 19:29:19 [error] 37221#37221: *56728 open()
"/opt/mailman/mm/static/CACHE/js/output.3aaa7705d68a.js" failed (2: No such
file or directory), client: 172.68.2.67, server: mm3-lists.kictanet.or.ke,
request: "GET /static/CACHE/js/output.3aaa7705d68a.js HTTP/2.0", host: "
mm3-lists.kictanet.or.ke", referrer: "
https://mm3-lists.kictanet.or.ke/archives/"
```
And the archives page is still br0ken,
--
Best regards,
Odhiambo WASHINGTON,
Nairobi,KE
+254 7 3200 0004/+254 7 2274 3223
In an Internet failure case, the #1 suspect is a constant: DNS.
"Oh, the cruft.", egrep -v '^$|^.*#' ¯\_(ツ)_/¯ :-)
[How to ask smart questions:
http://www.catb.org/~esr/faqs/smart-questions.html]
10 months, 3 weeks

[MM3-users] Re: moving lists to another server
by Odhiambo Washington
On Sat, Nov 18, 2023 at 1:42 AM Mark Sapiro <mark(a)msapiro.net> wrote:
> On 11/17/23 00:51, Odhiambo Washington wrote:
>
> > I am scratching my head bald trying to figure out how to bring in this
> > other MM3 site and list into my existing server, especially with regard
> to
> > the DB backend.
> >
> > The list - let's call it users(a)domainX.name was using MySQL backend and
> > had a separate DB for Mailman core and Mailman web.
> > I believe combining these into one isn't a problem. But getting to merge
> > this DB into my current one is what I am not sure about.
>
> This is https://gitlab.com/mailman/postorius/-/issues/13 which is a real
> need, but doesn't yet exist.
>
> I think the easiest thing for the archives is to forget the Mailman web
> DB and just export the archive as a mbox from the other site (if it's
> large, exporting the entire archive will time out so you have to do it
> in pieces). Then you can use hyperkitty_import to import it.
>
What is the command to export the archive as a mbox from the DB?
I can't figure out which option it is by looking at 'mailman-web -h'.
> For the list data, it's probably easiest to just create the list
> manually and go through the settings in Postorius and make them match,
I want to go with the above.
although you could dump the mailinglist table entry where list_id =
> 'users(a)domainx.name' and load that, but you'd need to edit the id field
> in the dump to match the id on your server.
Not going with that.
> That leaves the members.
Given that I have a dump of the two DBs (mailman and mailman-web) I just
created one DB and imported them.
I have been able to dump the members into a text file. Now importing is not
a problem.
BTW, how will ' mailman addmembers' treat a file containing:
```
Firstname Lastname <email@address>
Onlyname <email2@address>
```
?
> Doing this with a DB dump/load would be very complex because while the
> member table has a list_id field which is the id of the list's entry in
> the mailinglist table and can be used to select the relevant members,
> these records also link to entries in the address, preferences and user
> tables and matching them would be an issue.
>
I am also not taking that path.
I think a custom script would be required. If I were doing this, I would
> make a separate database on my server with a copy of the data from the
> other server and then try to make a script that would extract data from
> the other database and add it to mine.
Alternatively you could just dump the members from the other servers
> with the `mailman members` command perhaps separately for regular and
> the different digest types and then add them with the `mailman
> addmembers` command. This wouldn't get all their attributes, but it
> could work.
>
I have opted for the simple way to do this:
1. Create the site in Django Admin and create/configure the list in
Postorius
2. Add the members from the file dump, with delivery set to regular.
3. Send the members an email informing them that they need to set their
delivery preferences.
I am stuck on the issue of exporting the archives to mbox file as already
stated above.
--
Best regards,
Odhiambo WASHINGTON,
Nairobi,KE
+254 7 3200 0004/+254 7 2274 3223
"Oh, the cruft.", egrep -v '^$|^.*#' ¯\_(ツ)_/¯ :-)
[How to ask smart questions:
http://www.catb.org/~esr/faqs/smart-questions.html]
1 year, 7 months

[MM3-users] Re: django-allauth failures, but only for some users (independent of browser?)
by Jered Floyd
This was a related issue. See https://github.com/pennersr/django-allauth/pull/3554
--Jered
--- a/allauth/socialaccount/models.py
+++ b/allauth/socialaccount/models.py
@@ -144,7 +144,7 @@ class SocialAccount(models.Model):
return provider
def get_provider_account(self):
- return self.get_provider().wrap_account(self)
+ return self.get_provider(context.request).wrap_account(self)
class SocialToken(models.Model):
----- On Dec 6, 2023, at 7:57 PM, Mark Sapiro mark(a)msapiro.net wrote:
> On 12/6/23 14:49, Jered Floyd wrote:
>>
>> The difference in behavior was using social login buttons for an existing
>> account vs. creating a new account.
>>
>> This is another damn django-allauth regression, starting in 0.57.0. It seem to
>> be this commit that is to blame:
>> https://github.com/pennersr/django-allauth/commit/be779dfee5a328a3a42edc2c9…
>>
>> In allauth/socialaccount/models.py:lookup(self):285 there is an attempt to look
>> up the social account as one that already exists. If that fails, this commit
>> calls self.account.get_provider() without passing the request object, which
>> leads to the eventual error.
>>
>> I believe this is a django-allauth bug, and have submitted a pull request to fix
>> it here:
>> https://github.com/pennersr/django-allauth/pull/3548
>
> Thanks for all your work on this. It is much appreciated. However, your
> patch doesn't fix my issue with the URL
> https://example.com/accounts/social/connections/ which still produces
> the following:
> ```
> ERROR 2023-12-07 00:05:55,032 169452 django.request Internal Server
> Error: /accounts/social/connections/
> Traceback (most recent call last):
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/core/handlers/exception.py",
> line 55, in inner
> response = get_response(request)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/core/handlers/base.py",
> line 220, in _get_response
> response = response.render()
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/response.py",
> line 114, in render
> self.content = self.rendered_content
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/response.py",
> line 92, in rendered_content
> return template.render(context, self._request)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/backends/django.py",
> line 61, in render
> return self.template.render(context)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 175, in render
> return self._render(context)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 167, in _render
> return self.nodelist.render(context)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 1005, in render
> return SafeString("".join([node.render_annotated(context) for node
> in self]))
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 1005, in <listcomp>
> return SafeString("".join([node.render_annotated(context) for node
> in self]))
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 966, in render_annotated
> return self.render(context)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/loader_tags.py",
> line 157, in render
> return compiled_parent._render(context)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 167, in _render
> return self.nodelist.render(context)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 1005, in render
> return SafeString("".join([node.render_annotated(context) for node
> in self]))
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 1005, in <listcomp>
> return SafeString("".join([node.render_annotated(context) for node
> in self]))
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 966, in render_annotated
> return self.render(context)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/loader_tags.py",
> line 157, in render
> return compiled_parent._render(context)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 167, in _render
> return self.nodelist.render(context)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 1005, in render
> return SafeString("".join([node.render_annotated(context) for node
> in self]))
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 1005, in <listcomp>
> return SafeString("".join([node.render_annotated(context) for node
> in self]))
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 966, in render_annotated
> return self.render(context)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/loader_tags.py",
> line 157, in render
> return compiled_parent._render(context)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 167, in _render
> return self.nodelist.render(context)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 1005, in render
> return SafeString("".join([node.render_annotated(context) for node
> in self]))
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 1005, in <listcomp>
> return SafeString("".join([node.render_annotated(context) for node
> in self]))
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 966, in render_annotated
> return self.render(context)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/loader_tags.py",
> line 63, in render
> result = block.nodelist.render(context)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 1005, in render
> return SafeString("".join([node.render_annotated(context) for node
> in self]))
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 1005, in <listcomp>
> return SafeString("".join([node.render_annotated(context) for node
> in self]))
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 966, in render_annotated
> return self.render(context)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/loader_tags.py",
> line 63, in render
> result = block.nodelist.render(context)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 1005, in render
> return SafeString("".join([node.render_annotated(context) for node
> in self]))
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 1005, in <listcomp>
> return SafeString("".join([node.render_annotated(context) for node
> in self]))
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 966, in render_annotated
> return self.render(context)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/defaulttags.py",
> line 321, in render
> return nodelist.render(context)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 1005, in render
> return SafeString("".join([node.render_annotated(context) for node
> in self]))
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 1005, in <listcomp>
> return SafeString("".join([node.render_annotated(context) for node
> in self]))
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 966, in render_annotated
> return self.render(context)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/defaulttags.py",
> line 238, in render
> nodelist.append(node.render_annotated(context))
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 966, in render_annotated
> return self.render(context)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/defaulttags.py",
> line 539, in render
> values = {key: val.resolve(context) for key, val in
> self.extra_context.items()}
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/defaulttags.py",
> line 539, in <dictcomp>
> values = {key: val.resolve(context) for key, val in
> self.extra_context.items()}
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 715, in resolve
> obj = self.var.resolve(context)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 847, in resolve
> value = self._resolve_lookup(context)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/template/base.py",
> line 914, in _resolve_lookup
> current = current()
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/allauth/socialaccount/models.py",
> line 147, in get_provider_account
> return self.get_provider().wrap_account(self)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/allauth/socialaccount/models.py",
> line 141, in get_provider
> provider = self._provider = adapter.get_provider(
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/allauth/socialaccount/adapter.py",
> line 204, in get_provider
> app = self.get_app(request, provider=provider)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/allauth/socialaccount/adapter.py",
> line 284, in get_app
> apps = self.list_apps(request, provider=provider, client_id=client_id)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/allauth/socialaccount/adapter.py",
> line 231, in list_apps
> db_apps = SocialApp.objects.on_site(request)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/allauth/socialaccount/models.py",
> line 27, in on_site
> site = get_current_site(request)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/contrib/sites/shortcuts.py",
> line 16, in get_current_site
> return Site.objects.get_current(request)
> File
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/contrib/sites/models.py",
> line 63, in get_current
> raise ImproperlyConfigured(
> django.core.exceptions.ImproperlyConfigured: You're using the Django
> "sites framework" without having set the SITE_ID setting. Create a site
> in your database and set the SITE_ID setting or pass a request to
> Site.objects.get_current() to fix this error.
> ```
>
> --
> Mark Sapiro <mark(a)msapiro.net> The highway is for gamblers,
> San Francisco Bay Area, California better use your sense - B. Dylan
>
> _______________________________________________
> Mailman-users mailing list -- mailman-users(a)mailman3.org
> To unsubscribe send an email to mailman-users-leave(a)mailman3.org
> https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/
> Archived at:
> https://lists.mailman3.org/archives/list/mailman-users@mailman3.org/message…
>
> This message sent to jered(a)convivian.com
1 year, 6 months

[MM3-users] GNU Mailman condemns reinstatement of RMS
by Abhilash Raj
To the Mailman community,
The GNU Mailman Steering Committee condemns the reinstatement of
Richard M. Stallman (RMS) to the Board of the Free Software Foundation
(FSF), and has taken the following actions:
1. On behalf of the GNU Mailman project, signed the letter on
GitHub[1] calling for the removal of the entire FSF Board, as well
as RMS himself.
2. Started exploring ways to move our financial assets, for decades
managed by the FSF, to new management. The management fees are
small, but this is an important symbolic protest.
3. Started exploring how to leave the GNU Project. On the one hand,
if we leave but GNU wants to maintain a "GNU Mailman" project, we
cannot stop them, confusing users. On the other hand, RMS is
leader of the GNU Project, and has intervened in Mailman affairs
on many occasions. We should forestall this in the future.
We wish to explain our actions to the community.
Although free exchange of software among users is a practice that goes
back to days of the earliest general purpose computers, RMS was the
first to propose a complete free software distribution, and is the
acknowledged founder of the Free Software movement. Even leaders of
the Berkeley Software Distribution (BSD) acknowledge this. We all owe
him a debt for this.
Nevertheless, the movement has matured and thrived, spawning the
competitive open source movement, with whose philosophy Mailman is
more closely aligned. While we acknowledge our debt to RMS, we don't
need him any longer. And unfortunately, he has become both a symbol
and a source of the toxicity in tech communities. The FSF Board did
the right thing by accepting RMS's resignation. They did the wrong
thing by reinstating him.
RMS has a long history of abusive behavior and toxic political
positions. A small part of it is described in the open letter on
GitHub[1] and its references[2], and several members of the Steering
Committee have observed it directly. All of us have heard stories
directly from those who were abused or observed it directly. His
political positions are public, for example his support of pedophiles.
He claims that he in no way supports abusive relationships with
children, yet refuses to acknowledge that children are generally in
no position to provide consent, an evasive and highly toxic position.
There is no question: RMS is toxic.
We came for mailing list management, but we stayed for the community.
We have a right to protect our community by dissociating it from toxic
influences.
We do not want our project associated with such a person, nor to
provide economic resources to organizations that promote him to
leadership positions. We are taking these actions to protect our
community, both the narrow community of Mailman developers and users,
and the broader open source community, from his toxic behavior and
from the reputational damage that will come from helping to enable
him.
While we have no information suggesting that other members of the FSF
Board are similarly toxic as individuals, as a group they enabled RMS
for decades, and now have taken an explicit step in enabling him
again. If they want to regain their position of respect and
acceptance in our community, they must acknowledge their error, and we
don't see -- given their reinstatement of RMS himself -- how they can
do so convincingly while maintaining their positions on the Board.
They must resign, and a new Board composed, to demonstrate their
sincerity. What they do is up to them, of course, but if they do not
take radical steps, we will continue to consider association with the
FSF a threat to our community.
For the Mailman community,
Abhilash Raj (project leader)
Mark Sapiro
Stephen J. Turnbull
Aurélien Bompard
Terri Oda
Barry Warsaw
John Viega (founder)
[1] Text and signatures: https://rms-open-letter.github.io
[2] Appendix to the letter: https://rms-open-letter.github.io/appendix
Related statements: https://rms-open-letter.github.io/statements
4 years, 2 months

[MM3-users] Custom templates (was: Re: Re: nginx configuration on a multitasking server)
by David Newman
On 12/23/21 10:39 AM, Mark Sapiro wrote:
> On 12/23/21 9:57 AM, David Newman wrote:
>>
>> The task-pending message that MM3 sends to list owners and moderators
>> just says generically to check the dashboard, without providing a URL.
>>
>> Can that be modified to provide an explicit URL, something like this?
>>
>> https://lists.example.com/mailman3/lists/listname
>
>
> Yes, That particular message is built from the list:admin:action:post
> template. You may wish to make custom versions of that and other
> templates. The templates and their default values are at
> https://gitlab.com/mailman/mailman/-/tree/master/src/mailman/templates/en
>
> You can make custom versions of templates in two ways. You can create if
> necessary a /opt/mailman/mm/var/templates directory (it probably already
> exists). Within that directory, sitewide English templates are put in
> the site/en/ directory, domain specific English templates are put in the
> domains/<domain_name>/en/ directory and list specific English templates
> are put in the lists/<list_id>/en/ directory.
>
> For templates like this, you probably want sitewide ones. E.g.,
> site/en/list:admin:action:post.txt
> ---------------------------------------------------------------
> As list administrator, your authorization is requested for the
> following mailing list posting:
>
> List: $listname
> From: $sender_email
> Subject: $subject
>
> The message is being held because:
>
> $reasons
>
> At your convenience, visit
> https://lists.example.com/mailman3/lists/$list_id/held_messages
> to approve or deny the request.
> ---------------------------------------------------------------
>
> The other way to create custom templates is via Postotrius, but
> Postorius only creates list and domain specific templates. Also, if you
> create a template in Postorius, it overrides any in
> /opt/mailman/mm/var/templates/ until you delete it in Postorius.
>
> Info about templates and what substitution variables can be used is at
> https://docs.mailman3.org/projects/mailman/en/latest/src/mailman/rest/docs/…
Following up on this thread from a few weeks ago, a custom subscribe
template I defined is not getting sent out.
I created a pending subscription request on a test list. Here is the
text I'm using in a file called 'list:admin:action:subscribe.txt' (minus
the rows of hypens):
----------
As list administrator, your authorization is required for a mailing list
subscription request approval:
For: $member
List: $listname
At your convenience, visit:
https://${domain}/mailman/admindb/lists/${short_listname}.${domain}/
to approve or deny the request.
----------
Instead the message that goes out at midnight daily reads like this:
----------
The test(a)lists.domain.tld list has 1 moderation requests waiting.
Held Subscriptions:
User: letmein(a)domain.tld
Please attend to this at your earliest convenience.
----------
On successive nights I have placed copies of the
'list:admin:action:subscribe.txt' file above in these locations:
mm/var/templates/lists/test.lists.domain.tld/en
/opt/mailman/mm/var/templates/site/en
and then in Postorius, with the same contents as above. The file
versions are owned by the mailman user, and have 0644 permissions. Not
sure this is necessary but I've restarted the mailman3 and mailmanweb
services each time after a change.
There is no sign of trouble in the MM3 or web logs. The only thing I see
is in the Postfix log, where the shorter and less helpful message goes
out each night. I don't see anything in the template docs about this.
Questions:
1. What to do to get the custom message working?
2. Is there a way to trigger a subscribe reminder for one list only?
Asking because there are other lists on this server with other requests
pending, and I don't want to bother other moderators with multiple
reminders per day. Not a big deal, but it would be nice to test this
with one list rather than waiting up to 24 hours after each change.
Thank you!
dn
3 years, 5 months

[MM3-users] Re: Mails are not archived at all -- how to check if Hyperkitty is running or not?
by Tamas HOLCZER
Hi Franklin,
when I installed mailman3 on Debian I had some issues. One was about
MAILMAN_ARCHIVER_FROM. It turned out, that the request to Hyperkitty was
sent from one of the real IPs of the machine (not from localhost). This
depends on the interfaces and the routing of that machine. In my case
the solution was something like:
MAILMAN_ARCHIVER_FROM = ('127.0.0.1', '::1', '1.2.3.4', '1.2.3.5') ,
where 1.2.3.4 and 1.2.3.5 are the IP addresses of the machine running
mailman3 (I have not debugged if it is using .4 or .5 in reality I left
both of them there). Give it a try with your IPs.
Tamás
2019. 10. 30. 8:52 keltezéssel, Franklin Weng írta:
> Hi,
>
> It looks like to have some clues now.
>
> Mark Sapiro <mark(a)msapiro.net> 於 2019年10月30日 週三 13:07 寫道:
>
>> On 10/29/19 8:21 PM, Franklin Weng wrote:
>>> Yes, it is checked.
>> Have you checked Mailman's logs - Mailman's var/logs/mailman.log in
>> particular?
>>
> I found some hyperkitty URL error:
>
> The default settings of base_url in mailman-hyperkitty.cfg is defined as
>
> base_url: http://localhost/mailman/hyperkitty/
>
> In the mailman.log there are messages like:
>
> Oct 30 13:53:43 2019 (14259) HyperKitty failure on
> http://localhost/mailman3/hyperkitty/api/mailman/archive: <!DOCTYPE HTML
> PUBLIC "-//IETF//
> DTD HTML 2.0//EN">
> <html><head>
> <title>404 Not Found</title>
> </head><body>
> <h1>Not Found</h1>
> <p>The requested URL was not found on this server.</p>
>
> I changed it to
>
> base_url: https://localhost/mailman3/hyperkitty/
>
> then the log became
>
> File "/usr/lib/python3/dist-packages/requests
> /adapters.py", line 514, in send
> raise SSLError(e, request=request)
> requests.exceptions.SSLError: HTTPSConnectionPool(host='localhost',
> port=443): Max retries exceeded with url:
> /mailman3/hyperkitty/api/mailman/archive?key=xxx (Caused by
> SSLError(SSLCertVerification Error("hostname 'localhost' doesn't match '
> lists.slat.org'")))
>
> which makes sense because the SSL certificate applied from Letsencrypt is
> for lists.slat.org.
>
> If I use
>
> base_url: https://lists.slat.org/mailman3/hyperkitty/
>
> The log became
>
> Oct 30 15:25:50 2019 (6256) HyperKitty failure on
> https://lists.slat.org/mailman3/hyperkitty/api/mailman/urls:
> <html><title>Auth required</title><body>
>
> <h1>Authorization Required</h1>
> </body></html> (401)
>
> In my mailman-web.py:
>
> MAILMAN_ARCHIVER_KEY = 'my-key,same as in mailman-hyperkitty.cfg'
> MAILMAN_ARCHIVER_FROM = ('127.0.0.1', '::1')
>
> Not sure what to change here.
>
>
>> Do messages received from the list have an Archived-At: header?
>>
> Yes, but it's empty
>
>
> List-Id: 測試論壇 <slat-list.lists.slat.org>
> Archived-At: <>
> List-Archive: <>
> List-Help: <mailto:slat-list-request@lists.slat.org?subject=help>
> List-Post: <mailto:slat-list@lists.slat.org>
> List-Subscribe: <mailto:slat-list-join@lists.slat.org>
> List-Unsubscribe: <mailto:slat-list-leave@lists.slat.org>
>
>
>
>> What's in /etc/mailman3/mailman-hyperkitty.cfg? In particular does the
>> [general] setting base_url define a URL that accesses hyperkitty
>
> It seems to be the question…
>
>
> and
>> does the [general] setting api_key match the MAILMAN_ARCHIVER_KEY
>> setting in /etc/mailman3/mailman-web.py, but note that the
>> MAILMAN_ARCHIVER_KEY setting is quotes because it is a Python string
>> assignment and the api_key setting is not quoted
>>
> Yes, it's single quoted.
>
>
> Thanks for all your help!
>
>
> Franklin
> _______________________________________________
> Mailman-users mailing list -- mailman-users(a)mailman3.org
> To unsubscribe send an email to mailman-users-leave(a)mailman3.org
> https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/
5 years, 8 months

[MM3-users]Re: mailman 2 vs. mailman 3: what happened to multipart/digest?
by John Hein
Here's an '02 reference in git to the some heritage for multipart/digest
==========
commit 63d2568fe58333f8ca0b7582f74b43e775c581cd
Author: bwarsaw <>
Date: Thu Jul 11 22:14:25 2002 +0000
send_i18n_digests(): Let's generate MIME digests the correct way, by
wrapping each message inside the multipart/digest in a MIMEMessage
instance. We also no longer need to initialize the mimedigest
instance's payload to the empty list.
Also, when sending the digests, be sure to include isdigest=1 in the
metadata, otherwise SMTPDirect will try to tack on another footer.
==========
John wrote at 16:46 -0600 on May 12, 2016:
> Mark Sapiro wrote at 12:18 -0700 on May 12, 2016:
> > On 5/12/16 9:16 AM, John wrote:
> > > Digest delivery in mailman 2 encapsulated the individual message/rfc822 messages in a multipart/digest container. This allowed email clients to show the messages in the particular digest in a threaded view.
> >
> >
> > This format vs. plain text digests was a user option in Mailman 2.
> >
> >
> > > It seems like the various digest options that I have tried [1] in mailman 3.1.0 (as implemented for the fedora-users mailing list) no longer encapsulate messages in multipart/digest.
> >
> >
> > The core still supports the same plain text and MIME format digests and
> > the same individual subscriber and per-list default formats as did
> > Mailman 2. The issue is none of these things are exposed in Postorius.
> >
> > If you subscribe to digests on this list, you will receive the
> > 'encapsulated' MIME format because the lists mime_is_default_digest
> > setting is True, but currently that has to be set through the
> > bin/mailman shell tool.
> >
> >
> > > Is this intentional? Is it a bug - feature that was lost in translation from 2 to 3? Is there a delivery option I'm missing that will turn that back on?
>
> Thanks for the info - and Barry's reply as well. I understand that
> MIME digests are supported in Mailman 3 - that's what I'm using (and
> thanks, Barry, for the info that Summary Digests is the same right
> now). My quibble is that the multipart/digest encapsulation level is
> gone.
>
> Barry Warsaw wrote at 15:16 -0400 on May 12, 2016:
> > The MIME format of MIME digests should roughly be:
> >
> > multipart/mixed
> > text/plain (the digest heading)
> > text/plain (the TOC)
> > message/rfc822
> > message-1
> > message/rfc822
> > message-2
> > ...
> > text/plain (footer)
>
>
> But mm 2 had:
>
> multipart/mixed
> text/plain (the digest heading)
> text/plain (the TOC)
> multipart/digest <--- this is the part that's gone in mm3
> message/rfc822
> message-1
> message/rfc822
> message-2
> ...
> text/plain (footer)
>
> So was that removal intentional, a bug or ??
>
> Maybe you're saying there is definitely an unexposed (in Postorius)
> knob for that in mm3.
>
> >
> > It is the intent that Postorius will eventually expose all these
> > settings. We're not there yet. At present you could possibly do this by
> > interacting with mailmanclient, although I'm not certain the settings
> > are exposed there. You can do it via bin/mailman shell if you have
> > access and know what you're doing (see
> > <http://mailman.readthedocs.io/en/release-3.0/src/mailman/runners/docs/diges…>)
> >
> > If you file an issue at
> > <https://gitlab.com/mailman/postorius/issues/new>, it might help
> > expedite this.
>
> Okay.
> _______________________________________________
> Mailman-users mailing list
> mailman-users(a)mailman3.org
> https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/
9 years, 1 month

[MM3-users] Re: Wrong info in moderation mail when held due to match of a header rule
by tlhackque
On 17-Oct-20 18:40, Mark Sapiro wrote:
> On 10/17/20 1:31 PM, tlhackque via Mailman-users wrote:
>> I might also add the rule number or config filename:line, as in
>>
>> Header "{name}": rule in {file}:{n} matched value "{value}"
>>
>> This would be helpful when backtracking from a rejected message to the
>> cause.
>>
>> A sample expansion might be:
>>
>> Header "X-Spam": rule in foo.conf:83 matched value "yes"
>
> These rules are not in a configuration file. They are in the headermatch
> table in the database and the rules for a particular list are exposed on
> the Header filters tab in Postorius or at the REST
> lists/LISTNAME/header-matches endpoint.
>
> Perhaps something like
>
> {name}: header match rule, pattern "{pattern}" matched value "{value}"
>
> example:
>
> subject: header match rule, pattern "sex|long|list|of|other|bad|words"
> matched value "This is a post about filtering based on words like sex in
> the subject."
>
> but that could be just adding more clutter.
>
I considered including the regex in each message, but that seemed
redundant - and potentially long. Thus the pointer. Perhaps number the
rules for each list, and use that index? The ROWID would seem to be a
candidate for the number.
Then Postorius could simply number the rules in its tab; the REST API
can add the ROWID as a rule_ID field in the returned JSON. (The fact
that it's a ROWID rather than an index or unique name is an
implementation detail.)
If many rules are anticipated, it might want an endpoint or option to
fetch a rule by ID. Then it would be easy to drill down on a specific
event for diagnosis.
e.g.
shunt_reason: (or whatever) {
cause: "header_match"
header: "subject"
header_value: "This is a post about filtering based on words like sex
in the subject."
rule_id: 47 /* or pattern_id? */
}
displays as
subject: header match rule 47, matched value "This is a post about
filtering based on words like sex in
the subject."
and
lists/LISTNAME/header-matches/47 returns {
rule_id: 47
pattern: "sex|long|list|of|other|bad|words"
position: 3
/* Whatever else is in your table... I haven't looked since I postponed
using MM3. eg */
comment:"Required by policy 869.202"
last_updated_by: "Corporate Prude"
last_updated_on: "1-Apr-1762"
}, while
lists/LISTNAME/header-matches returns an array of those structures,
presumably as today.
With those capabilities, the UI can be enhanced so that clicking on a
shunted message gives the summary reason, and clicking on the summary
gives the regex. I expect that the header and value will be sufficient
for understanding an issue most of the time. Looking at the regex is
less common, and only necessary when it needs to be updated...
I still think that it is more readable and less verbose to order the
message as a declarative sentence:
Header "subject": rule 47 matched value "sex"
but that may be a matter of personal taste. The UI can sort that out...
Note that from your description, using ROWID may cause rules in a
particular list to have gaps in the rule numbering. I don't think
that's a big issue, though Postorious could paper that over - perhaps
use the position attribute. Doesn't seem worth doing something more
complex. The advantage is that it doesn't require any DB change now.
But aliasing it to "rule_id" allows for any future demand to name the
rules or use some other numbering scheme.
I may have some details wrong - I found mm3 not ready for my needs and
am thus out of date - but I hope the high level approach that I outlined
is useful.
4 years, 8 months