Search results for query "sapiro"
- 5653 messages

[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

[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, 5 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

[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, 6 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, 9 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, 8 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, 5 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, 8 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, 10 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, 8 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, 2 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, 2 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, 5 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, 5 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, 3 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, 8 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, 9 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

[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, 8 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]
9 months, 3 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, 4 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, 8 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, 2 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

[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, 5 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, 1 month

[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, 9 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, 7 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, 8 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, 10 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.
>
4 months, 2 weeks

[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, 1 month

[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, 2 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, 7 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, 5 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, 3 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, 2 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

[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, 2 months

[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, 5 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, 10 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, 7 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, 3 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, 6 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

[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
6 months, 3 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, 1 month

[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, 2 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:
1 year, 11 months

[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, 3 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, 7 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
6 years, 11 months

[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, 3 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, 9 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, 3 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, 8 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

[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.
4 years, 11 months

[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: 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, 3 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, 3 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, 2 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, 5 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, 4 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, 7 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, 2 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, 10 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, 10 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, 3 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, 9 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

[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, 6 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

[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, 4 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, 10 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, 3 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, 3 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, 3 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

[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
1 month, 1 week

[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, 8 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

[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
1 year, 11 months

[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, 2 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, 7 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, 2 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, 7 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/
4 years, 11 months

[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, 2 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, 6 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, 6 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]
10 months, 1 week

[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, 5 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, 5 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

[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, 7 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, 3 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
6 days, 18 hours

[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, 8 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, 7 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, 1 month

[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, 5 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.
4 years, 11 months

[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.
3 years, 11 months

[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, 10 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

[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, 3 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
8 months, 1 week

[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)
4 years, 11 months

[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
6 months, 4 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, 4 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, 8 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, 7 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

[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, 6 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, 1 month

[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, 4 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, 7 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

[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, 7 months

[MM3-users] Re: Mailman stopping message distribution because of SMTP errors
by Victoriano Giralt
El mié, 12-02-2020 a las 13:28 -0800, Mark Sapiro escribió:
> On 2/11/20 10:28 PM, Victoriano Giralt wrote:
> >
> > I have recently migrated some lists from Mailman 2 to Mailman 3. Users
> > have
> > been added using the mailman client as pre-verified addresses so the
> > migration happened "silently". Thus, there was a dozen "bad" addresses
> > (domains that did not exist anymore).
>
>
> It seems you rolled your own instead of using `mailman import21`. Is
> there a reason for this?
Yes, no access to the previous server command line. So, to tell the truth
it was not a "real" migration, my excuses.
> > Unfortunately, Mailman got some of the "bad" addresses in the first
> > message
> > batch for sending out, so, Postfix closed the connection because of
> > "too
> > many errors" and this stopped the process completely, i.e. Mailman did
> > not
> > continue sending messages to the rest of the list over 600 addresses.
>
>
> Is the message shunted? Is there a traceback and a shunting message in
> mailman.log?
>
> Normally, I would expect the message to be queued in Mailman's retry
> queue and retried by Mailman
Yes, it was being retried every 15 minutes with the same result: stopped
distribution after the first attempt with the first address batch. Also
reprocessing the "retry" files with mailman command interface.
> > There was no more information in the logs than the Postfix error
> > messages
> > in smtp.log.
My bad, the errors where in the system maillog where Postfix complains.
> What was in the smtp.log?
This (redacted to protect the innocent):
Feb 05 16:29:44 2020 (86791) ('127.0.0.1', 51146) recip: listname
@example.org
Feb 05 16:30:16 2020 (86797) <messageid(a)example.com> smtp to listname
@example.org for 634 recips, completed in 29.087315797805786 seconds
Feb 05 16:30:16 2020 (86797) <messageid(a)example.com> post to listname
@example.org from sender(a)example.com, 4354 bytes, 9 failures
Feb 05 16:30:20 2020 (86791) ('127.0.0.1', 51642) Data: b'RCPT TO:<listname
-bounces(a)example.org>'
Feb 05 16:30:20 2020 (86791) ('127.0.0.1', 51642) recip: listname
-bounces(a)example.org
Feb 05 16:30:43 2020 (86791) ('127.0.0.1', 51870) Data: b'RCPT TO:<listname
-bounces(a)example.org>'
Feb 05 16:30:43 2020 (86791) ('127.0.0.1', 51870) recip: listname
-bounces(a)example.org
...
rinse and repeat every 15 minutes ...
> Nothing in mailman.log?
Nothing at all about SMTP/LMTP
> Nothing in var/queue/shunt?
Nothing there, a .psv file in var/spool/mailman/bad/ and two .pck files in
retry/
> Once the "bad" addresses were removed, the list started working as
> > expected.
> >
> > I consider this a bug. The bouncing addresses should have been marked
> > as
> > "non deliverable" and the subscriptions "paused" and the rest should
> > have
> > been delivered. Or, the list owner should have been notified that there
> > was
> > a problem with message distribution. None of these happened.
>
>
> The HEAD of the https://gitlab.com/mailman/mailman master branch
> implements bounce processing. This will be in 3.3.1 which is not yet
> released.
>
> The place for a bug report is <https://gitlab.com/mailman/mailman/issues>
Well, if 3.3.1 has bounce processing, I'd rather wait and test when it is
released instead of adding "noise" in the bug tracker, right?
My problem was solved with a workaround: find and remove the "bad"
addresses. Let's leave this as reference in the archives in case someone
hits the same problem.
--
Victoriano Giralt CIO
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 ?
5 years, 3 months

[MM3-users] Re: Mailman, etc. upgrade woes and persistent bugs
by Abhilash Raj
On Sun, Feb 14, 2021, at 8:59 AM, Allan Hansen wrote:
> Mark,
>
> Thank you for this reminder, but it’s not really sufficient for most.
> The ‘Mailman Settings’ dialog does, indeed show the other preferences
> tags, and yes, as you say, the dialog for ‘List-based preferences’ only
> shows values that are not inherited and when you set a value there, it
> shows.
>
> There a two problems with this:
>
> a. Once a value is overridden on the ‘List-based preferences’ dialog,
> you cannot go back to it being inherited by removing the override.
Yes! This is something we've known for a while and haven't been able
to fix properly.
https://gitlab.com/mailman/postorius/-/issues/414
https://gitlab.com/mailman/postorius/-/issues/195
There more than one open issue for this. And one of the reasons it
hasn't been fixed yet is that it is larger problem than most low hanging
fruits that gets fixed in the available time window for the us to work
on issue.
This is a long weekend for me, so I'll start some work on this, but not
sure if that would be enough to finish.
> b. You cannot see, on this dialog, what the inherited value is.
https://gitlab.com/mailman/postorius/-/issues/476
I opened an issue for this too, but this might be a little bit longer of
a task because the whole inheritance and calculation of effective
preference/setting happens in Core. It would require that Core
expose the effective values.
We do have some calculation of preferences in Postorius to display
the "Global Mailman preferences" page for a User.
> This is not user-friendly.
>
> May I suggest the following:
>
> That each option shows the following:
>
> o Value 1
> o Value 2
> (or the equivalent for pull-down menus)
>
> A box showing inheritance status:
> [ ] Use inherited value from address-based preference: Value2
>
> If the ‘Use inherited value’ is chosen, then the inherited value shows.
> but the value radio buttons become non-selectable.
It is a good idea, might need Javascript skills that I don't have ;-) I'll still
try to take a stab at implementing such a view.
> If not, then whatever value the value radio box has become the value
> for the list,
>
> From what I see, the ‘Use inherited value’ is the default for new
> lists/addresses. To change a value, the user would
> uncheck this box, making the radio buttons selectable, and then set the
> desired value.
>
> Yours,
>
> Allan
>
>
> > On Feb 12, 2021, at 11:52 , Mark Sapiro <mark(a)msapiro.net> wrote:
> >
> >> 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/ <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
>
> _______________________________________________
> 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: Mailman3 without Hyperkitty in docker
by Abhilash Raj
On Sat, Mar 2, 2019, at 1:09 AM, Danil Smirnov wrote:
> 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...
Done, triggered a build on Dockerhub.
docker.io/maxking/postorius:latest
This should be available when the build is done.
>
> Also it would be really great to extend image labelling used for *quay.io/maxking/mailman-*:rolling* images to Docker Hub ones... Version identification is quite hard for Docker...
rolling tags should be available on DockerHub too. They are replicated on both registries.
>
> 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)
>>
>>
--
thanks,
Abhilash Raj (maxking)
6 years, 3 months

[MM3-users] Re: Timeouts
by tlhackque
On 25-Apr-21 20:34, Mark Sapiro wrote:
> On 4/25/21 4:37 PM, tlhackque via Mailman-users wrote:
>
>> 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.
> It is not the web server that times out. I'm not sure about uwsgi
> because I don't use it, but the timeouts I see are on servers that use
> gunicorn as the WSGI interface to Django and the timeout is in a
> gunicorn worker. This is controlled by the timeout setting in the
> gunicorn config. <https://docs.gunicorn.org/en/stable/settings.html#timeout>
>
> Note that even 300 seconds is not enough to download the entire
> <https://mail.python.org/archives/list/python-dev@python.org/> archive.
>
> It may be possible to get HyperKitty to chunk the output to avoid this,
> but it doesn't currently do that. Care to submit an MR?
>
>
I'm afraid (u)WSGI, Django, and gunicorn are not technologies that I
work with.
It sounds as if hyperkitty is compiling the entire archive before
sending the first byte.
The gunicorn doc that you pointed to says
Workers silent for more than this many seconds are killed and restarted.
Setting it to 0 has the effect of infinite timeouts by disabling
timeouts for all workers entirely.
"Silent" sounds like the standard webserver "you have to push some bits,
or we assume you're stuck".
My understanding is that gunicorn is a Python persistence server that is
run behind a webserver proxy. So the (proxy) webserver (apache, nginx,
...) timeouts also apply and would need to be increased.
Might be interesting to try 0 (gunicorn) / 1200 (webserver) with your
python-dev archive, time it and see how much (encoded) data is
transferred... (I would expect most mailing list archives to compress
nicely, though those with binary attachments wont.)
But fiddling with timeouts is treating the symptom, not the root cause.
The right solution is to stream, segment (or chunk) the output, because
in the general case, no timeout is long enough. It'll always be
possible to find an archive that's just one byte (or second) longer than
any chosen timeout. (See the halting problem.) You want
the timeout
to catch a lack of progress, not total time that's a function of
transaction size. (Webservers may also have limits on transaction size
- e.g. mod_security, but they're only useful when the upper bound on a
response is knowable.) Thus, the timeout(s) should be roughly
independent of the archive size; on the order of time-to-first-byte
(which ordinarily is longer than time between segments/chunks).
Also note that streaming requires fewer server resources than compiling
a complete archive before sending, since you don't need to create the
entire archive in memory (or in a tempfile). You only need enough
memory to efficiently buffer the file I/O and to contain the compression
tables/output buffer. Except for trivial cases, this will be
independent of the archive size. The only downside is that if the comm
link is slow, you may hold a reader lock on the source data for longer
than necessary with the current scheme.
Seems as though this deserves an issue. I guess I could open one - but
you have the experience/test cases.
4 years, 1 month

[MM3-users] Re: Problem with missing MySQLDatabase
by Peter Sørensen
Hi Mark,
Unfortunately I answered on ³auto response not sent² instead of this -
sorry.
In the meantime I found one problem. The comment I¹ve put at the end of
line ## MOD ..
This is not the way to do it in Python. I normally use Perl and not a
Python as script language.
Deleteing the #Š Made this problem disappear but instead below problem
showed up.
/etc/mailman3# mailman aliases
Traceback (most recent call last):
File /usr/bin/mailman, line 11, in <module>
load_entry_point('mailman==3.1.1', 'console_scripts', 'mailman')()
File /usr/lib/python3/dist-packages/mailman/bin/mailman.py, line 94, in
main
initialize(config_path)
File /usr/lib/python3/dist-packages/mailman/core/initialize.py, line
189, in initialize
initialize_2(propagate_logs=propagate_logs)
File /usr/lib/python3/dist-packages/mailman/core/initialize.py, line
160, in initialize_2
config.db = getUtility(IDatabaseFactory, utility_name).create()
File /usr/lib/python3/dist-packages/mailman/database/factory.py, line
54, in create
database.initialize()
File /usr/lib/python3/dist-packages/mailman/database/base.py, line 106,
in initialize
self.engine = create_engine(url, isolation_level='READ UNCOMMITTED')
File /usr/lib/python3/dist-packages/sqlalchemy/engine/__init__.py, line
387, in create_engine
return strategy.create(*args, **kwargs)
File /usr/lib/python3/dist-packages/sqlalchemy/engine/strategies.py,
line 80, in create
dbapi = dialect_cls.dbapi(**dbapi_args)
File
/usr/lib/python3/dist-packages/sqlalchemy/dialects/mysql/pymysql.py, line
62, in dbapi
return __import__('pymysql')
ModuleNotFoundError: No module named Œpymysql'
I have installed pymysql with: pip install pymysql
When I do this once more I get
pip install pymysql
Requirement already satisfied: pymysql in
/usr/local/lib/python2.7/dist-packages
Requirement already satisfied: cryptography in
/usr/lib/python2.7/dist-packages (from pymysql)
So the problem has probably to do with this installed in python2.7 and not
python3.
How do I solve that ?
Best regards
Peter Sørensen
University of Southern Denmark
Den 19/10/18 19:13 skrev "Mark Sapiro" <mark(a)msapiro.net>:
>On 10/19/18 3:44 AM, Peter Sørensen wrote:
>> Hi,
>>
>> I have looked into installing this before without success but found
>> The Debian package Mailman3-full
>>
>> I installed this succesfully along with the mailman-suite.
>> I have configured varios setting but are stuck when trying to generate
>>aliases
>> For mailman with:
>>
>> mailman aliases
>> Traceback (most recent call last):
>> File /usr/bin/mailman, line 11, in <module>
>> load_entry_point('mailman==3.1.1', 'console_scripts', 'mailman')()
>> File /usr/lib/python3/dist-packages/mailman/bin/mailman.py, line 94,
>>in main
>> initialize(config_path)
>> File /usr/lib/python3/dist-packages/mailman/core/initialize.py, line
>>189, in initialize
>> initialize_2(propagate_logs=propagate_logs)
>> File /usr/lib/python3/dist-packages/mailman/core/initialize.py, line
>>160, in initialize_2
>> config.db = getUtility(IDatabaseFactory, utility_name).create()
>> File /usr/lib/python3/dist-packages/mailman/database/factory.py, line
>>52, in create
>> database = call_name(database_class)
>> File /usr/lib/python3/dist-packages/mailman/utilities/modules.py,
>>line 67, in call_name
>> named_callable = find_name(dotted_name)
>> File /usr/lib/python3/dist-packages/mailman/utilities/modules.py,
>>line 50, in find_name
>> __import__(package_path)
>> ModuleNotFoundError: No module named
>>'mailman.database.mysql.MySQLDatabase\t\t\t#MOD(inserted ) 02';
>>'mailman.database.mysql' is not a package
>>
>> I can see from the message that I¹m missing a module but I can¹t figure
>>out. how to get
>> This installed. The mudule is referenced in the mailman.cfg as
>> class: mailman.database.mysql.MySQLDatabase
>
>
>The module mailman.database.mysql is part of mailman core. In your case,
>it should be /usr/lib/python3/dist-packages/mailman/database/mysql.py.
>If that file exists, I don't know what the problem might be. If not,
>there is something wrong with your installation. In any case, this is a
>Debian issue. You need to take it up with Debian.
>
>--
>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/
6 years, 7 months

[MM3-users] Re: Mailman installation results in KeyError: 'env_py'
by Abhilash Raj
On Sun, Oct 22, 2017, at 09:36 AM, Marvin Gülker wrote:
> Am 22. October 2017 um 07:49 Uhr -0700 schrieb Mark Sapiro
> <mark(a)msapiro.net>:
> > or you can install the fix at
>
> Thanks. Applying this patch makes it work. Now I've got a different
> problem, though. I can't get it to connect to Postfix for sending
> emails it appears. After I created a superuser account using
>
> $ python manage.py createsuperuser
>
> as described on <http://postorius.readthedocs.io/en/latest/setup.html>,
> I tried to login using this credentials into Postorius. It then reported
> it sent a confirmation email to me (for an account I created on
> commandline?!), but Postfix' logs reveal that it didn't; there's not
> even a sign of an attempted delivery in /var/log/mail.log. I've
> configured the Postfix configuration in mailman.cfg like this:
>
> [mta]
> incoming: mailman.mta.postfix.LMTP
> outgoing: mailman.mta.deliver.deliver
> lmtp_host: 127.0.0.1
> lmtp_port: 8024
> smtp_host: localhost
> smtp_port: 25
> configuration: python:mailman.config.postfix
>
> as was outlined on
> <http://mailman.readthedocs.io/en/latest/src/mailman/docs/mta.html>.
>
> mailman-suite's settings.py contains:
>
> # Change this when you have a real email backend
> EMAIL_BACKEND = 'django.core.mail.backends.smtp.EmailBackend'
> EMAIL_HOST = 'localhost'
> EMAIL_PORT = 25
>
> which was described on <http://docs.list.org/en/latest/config-web.html>.
>
> For completeness, the following is in Postfix' main.cf, but is not the
> cause of the problem as it affects the incoming direction, whereas I
> refer to the outgoing one:
>
> transport_maps = hash:/home/mailman/var/data/postfix_lmtp
> local_recipient_maps = hash:/home/mailman/var/data/postfix_lmtp
>
> I failed to locate any kind of logging information about the failed
> email, so I don't even know where I should start looking for the
> problem. var/logs/smtp.log is empty in the mailman directory, and
> likewise is logs/mailmansuite.log in the mailman-suite_project
> directory.
As Simon mentioned, try using DEBUG=False, if you don't already have
that. With DEBUG=True, you should see emails printed in a `emails`
directory under `mailman-suite_project` directory.
This is a confirmation email to verify the email addresses, which
happens even if you create an account from command line.
> That being said, the enormous number of configuration files to consider
> and dozens of cross-references to other pages in the docs make the
> installation guide hard to follow; it also lacks logical structure in my
> opinion, when it refers to parts of the configuration which are later
> explained. For someone like me who never programmed a Django application
> (Ruby dev) this is all pretty cryptic. Especially, that some parts of
> information are on <http://docs.list.org/en/latest/index.html> whereas
> other parts are scattered over readthedocs.io makes it very
> complicated.
There are only two primary configuration files (there are a few more for
finer configurations ;-):
- mailman.cfg: This is the configuration for the Core engine and can be
located any of the places mentioned in [1] or pointed to by environment
var MAILMAN_CONFIG_FILE.
- settings.py: This is the configuration file for Django under
`mailman-suite_project` and controls the frontend (Postorius &
Hyperkitty). Django is a huge framework with literally 1000s of options.
It would be impossible to copy that information from Django's
documentation and keep it updated in our docs. Hence, we have links to
appropriate places when needed. Same goes out for the rest of the
libraries that we use.
All the settings mentioned in the documentation go to either of these
files, except, when configuring web server and mail server. Please open
an issue[2] if it is not clear where a particular configuration snippet
goes and we will fix it.
[1]: http://docs.mailman3.org/en/latest/config-core.html
[2]: https://gitlab.com/mailman/mailman-suite-doc/issues
Hope that helps!
--
Abhilash Raj
maxking(a)asynchronous.in
7 years, 7 months

[MM3-users] mailman-web migrate fails: KeyError: 'django'
by David Newman
Following the venv installation docs on a Debian 10 system, the command
"mailman-web migrate" fails with a "KeyError: 'django'" error.
Output pasted below [1].
There's an earlier thread on this error [2] but I think the cause may be
different. Even so, per Mark Sapiro's suggestion I changed STATIC_ROOT
to /opt/mailman/mm/var/static in settings.py. In mailman.cfg, var_dir is
at the default setting of /opt/mailman/mm/var/static.
I previously had tried creating /opt/mailman/mm/web/logs and chown'ing
it to mailman, but "mailman-web migrate" failed with the same error.
FWIW, mailman-web and hyperkitty installation initially failed with the
suggesting that I upgrade pip, which I did using " pip install --upgrade
pip".
Thanks in advance for troubleshooting clues.
dn
[1]
(venv) mailman@somehost:~$ mailman-web migrate
Traceback (most recent call last):
File
"/opt/mailman/venv/lib/python3.7/site-packages/django/template/utils.py", line
66, in __getitem__
return self._engines[alias]
KeyError: 'django'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File
"/opt/mailman/venv/lib/python3.7/site-packages/django/template/backends/django.py",
line 121, in get_package_libraries
module = import_module(entry[1])
File "/usr/lib/python3.7/importlib/__init__.py", line 127, in
import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "<frozen importlib._bootstrap>", line 1006, in _gcd_import
File "<frozen importlib._bootstrap>", line 983, in _find_and_load
File "<frozen importlib._bootstrap>", line 967, in
_find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 677, in _load_unlocked
File "<frozen importlib._bootstrap_external>", line 728, in exec_module
File "<frozen importlib._bootstrap>", line 219, in
_call_with_frames_removed
File
"/opt/mailman/venv/lib/python3.7/site-packages/hyperkitty/templatetags/decorate.py",
line 4, in <module>
from hyperkitty.lib.renderer import markdown_renderer, text_renderer
File
"/opt/mailman/venv/lib/python3.7/site-packages/hyperkitty/lib/renderer.py",
line 7, in <module>
from mistune.scanner import escape_html, escape_url
ImportError: cannot import name 'escape_html' from 'mistune.scanner'
(/opt/mailman/venv/lib/python3.7/site-packages/mistune/scanner.py)
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/opt/mailman/venv/bin/mailman-web", line 8, in <module>
sys.exit(main())
File
"/opt/mailman/venv/lib/python3.7/site-packages/mailman_web/manage.py",
line 30, in main
execute_from_command_line(sys.argv)
File
"/opt/mailman/venv/lib/python3.7/site-packages/django/core/management/__init__.py",
line 401, in execute_from_command_line
utility.execute()
File
"/opt/mailman/venv/lib/python3.7/site-packages/django/core/management/__init__.py",
line 395, in execute
self.fetch_command(subcommand).run_from_argv(self.argv)
File
"/opt/mailman/venv/lib/python3.7/site-packages/django/core/management/base.py",
line 328, in run_from_argv
self.execute(*args, **cmd_options)
File
"/opt/mailman/venv/lib/python3.7/site-packages/django/core/management/base.py",
line 366, in execute
self.check()
File
"/opt/mailman/venv/lib/python3.7/site-packages/django/core/management/base.py",
line 395, in check
include_deployment_checks=include_deployment_checks,
File
"/opt/mailman/venv/lib/python3.7/site-packages/django/core/management/commands/migrate.py",
line 64, in _run_checks
issues.extend(super()._run_checks(**kwargs))
File
"/opt/mailman/venv/lib/python3.7/site-packages/django/core/management/base.py",
line 382, in _run_checks
return checks.run_checks(**kwargs)
File
"/opt/mailman/venv/lib/python3.7/site-packages/django/core/checks/registry.py",
line 72, in run_checks
new_errors = check(app_configs=app_configs)
File
"/opt/mailman/venv/lib/python3.7/site-packages/django/contrib/admin/checks.py",
line 76, in check_dependencies
for engine in engines.all():
File
"/opt/mailman/venv/lib/python3.7/site-packages/django/template/utils.py", line
90, in all
return [self[alias] for alias in self]
File
"/opt/mailman/venv/lib/python3.7/site-packages/django/template/utils.py", line
90, in <listcomp>
return [self[alias] for alias in self]
File
"/opt/mailman/venv/lib/python3.7/site-packages/django/template/utils.py", line
81, in __getitem__
engine = engine_cls(params)
File
"/opt/mailman/venv/lib/python3.7/site-packages/django/template/backends/django.py",
line 25, in __init__
options['libraries'] = self.get_templatetag_libraries(libraries)
File
"/opt/mailman/venv/lib/python3.7/site-packages/django/template/backends/django.py",
line 43, in get_templatetag_libraries
libraries = get_installed_libraries()
File
"/opt/mailman/venv/lib/python3.7/site-packages/django/template/backends/django.py",
line 108, in get_installed_libraries
for name in get_package_libraries(pkg):
File
"/opt/mailman/venv/lib/python3.7/site-packages/django/template/backends/django.py",
line 125, in get_package_libraries
"trying to load '%s': %s" % (entry[1], e)
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.7/site-packages/mistune/scanner.py)
[2]
https://lists.mailman3.org/archives/list/mailman-users@mailman3.org/thread/…
3 years, 6 months

[MM3-users] Re: Badsignature on uwsgi-error.log
by David Partain
Hi Mark & all,
Thanks for the response. Just picking up where we are at the moment to provide a bit more info, in case you have ideas. Thanks, Stephen T. as well for the idea of turning on DEBUG. We might resort to that in the end.
This is what our system is running right now:
Mailman Core Version GNU Mailman 3.3.9 (Tom Sawyer)
Mailman Core API Version 3.1
Mailman Core Python Version 3.10.12 (main, Jun 11 2023, 05:26:28) [GCC 11.4.0]
As previously noted, we moved this off of an old Ubuntu package-based installation that has delivered mail reliably but many other things haven't worked well, so we're happy to be on something that might improve that situation.
Right now, archiving is not working on the new installation, both building the archive on the new installation after the move and for new messages.
uwsgi-error.log is getting blasted with constant errors along the lines of what follows. I suspect that these errors are why archiving isn't working, but I obviously don't know that:
Message: BadSignature('Signature "ZWBXqQmWZwHTfa390lLIacpp8NQ" does not match')
Arguments: ('Traceback (most recent call last):
File "/local/mailman/venv/lib/python3.10/site-packages/django_q/cluster.py", line 356, in pusher
task = SignedPackage.loads(task[1])
File "/local/mailman/venv/lib/python3.10/site-packages/django_q/signing.py", line 25, in loads
return signing.loads(
File "/local/mailman/venv/lib/python3.10/site-packages/django_q/core_signing.py", line 35, in loads
base64d = force_bytes(TimestampSigner(key, salt=salt).unsign(s, max_age=max_age))
File "/local/mailman/venv/lib/python3.10/site-packages/django_q/core_signing.py", line 70, in unsign
result = super(TimestampSigner, self).unsign(value)
File "/local/mailman/venv/lib/python3.10/site-packages/django_q/core_signing.py", line 55, in unsign
raise BadSignature(\'Signature "%s" does not match\' % sig)
django.core.signing.BadSignature: Signature "ZWBXqQmWZwHTfa390lLIacpp8NQ" does not match',)
What we have in our config files on the old installation and new installation are (the quotes are exactly as they are in the files):
Old installation:
mailman-web.py
SECRET_KEY = 'somerandomstringiaintputtinginmail'
MAILMAN_ARCHIVER_KEY = 'somerandomstringiaintputtinginmail'
mailman-hyperkitty.cfg
api_key: somerandomstringiaintputtinginmail
New installation:
settings.py
SECRET_KEY = 'somerandomstringiaintputtinginmail'
MAILMAN_ARCHIVER_KEY = 'somerandomstringiaintputtinginmail'
mailman-hyperkitty.cfg
api_key: somerandomstringiaintputtinginmail
All of that says that the value is the same for all three (whether I should have done so or not...) and those settings were carried along to the new installation as well.
Django is a big scary beast as I've not had to manage django apps before. Would it make sense that the error above is because what I _think_ django believes is the SECRET_KEY (in the config files above) is in fact not what django believes? Maybe it was set during installation (which I didn't do)? I don't believe anyone has purposefully changed it.
I suppose I could do something like https://medium.com/django-unleashed/securing-django-applications-best-pract… to reset the secret key, but I'm not doing that on Friday afternoon :)
If anyone has other thoughts, please holler. Wishing you all a good weekend from lighter-by-the-day Sweden.
Cheers,
David
-----Original Message-----
From: Mark Sapiro <mark(a)msapiro.net<mailto:Mark%20Sapiro%20%3cmark@msapiro.net%3e>>
To: mailman-users(a)mailman3.org<mailto:mailman-users@mailman3.org>
Subject: [MM3-users] Re: Badsignature on uwsgi-error.log
Date: Wed, 20 Mar 2024 18:12:20 -0700
On 3/20/24 14:25, Helio Loureiro wrote:
Hi,
I keep receiving a lot of errors like this:
--- Logging error ---
Traceback (most recent call last):
...
"/local/mailman/venv/lib/python3.10/site-packages/django_q/core_signing.py",
line 55, in unsign
raise BadSignature('Signature "%s" does not match' % sig)
django.core.signing.BadSignature: Signature "F6V0Dr_SvBsx5-cY8vcvLXrX8tA"
does not match
...
The api_key on mailman-hypperkitty.cfg, SECRET_KEY and MAILMAN_ARCHIVE_KEY
on setting.py are the same.
Of those three, the api_key on mailman-hypperkitty.cfg and
MAILMAN_ARCHIVE_KEY must match. SECRET_KEY is different. It is a Django
thing and has nothing to do with the others. See https://docs.djangoproject.com/en/5.0/ref/settings/#secret-key
If you changed it, that's the issue. If you know what it was previously,
you could set the previous value in SECRET_KEY_FALLBACKS, see https://docs.djangoproject.com/en/5.0/ref/settings/#secret-key-fallbacks
1 year, 2 months

[MM3-users] Re: Fwd: [Django] ERROR (EXTERNAL IP): Internal Server Error: /archives/search
by Odhiambo Washington
On Sat, Jan 28, 2023 at 7:44 PM Mark Sapiro <mark(a)msapiro.net> wrote:
> On 1/27/23 23:53, Odhiambo Washington wrote:
> >
> > I have reread what you wrote now and I'm beginning to get the hang of
> this
> > method.
> > My observation is that it can only be _obvious_ to someone very familiar
> > with Python config
> > to decipher that *additional* settings *that can be augmented or
> overridden
> > in /etc/mailman3/settings.py* can be obtained from:
> > /PATH-TO/mailman_web/settings/{base|mailman}.py after they have noticed
> > these two lines in
> > the sample settings given in /etc/mailman3/settings.py:
> >
> > from mailman_web.settings.base import *from
> > mailman_web.settings.mailman import *
>
>
> This is how it was always done in Mailman 2.1 and how it should have
> been done in Mailman 3's Django web UI from the start, but wasn't.
>
> MM 2.1 had mm_cfg.py which had
> ```
> from Defaults import *
>
> ##################################################
> # Put YOUR site-specific settings below this line.
> ```
>
>
> > [At first instance, it is not obvious that mailman_web.settings.base and
> > mailman_web.settings.mailman are
> > actually paths in Python - which magically translates to
> > mailman_web/settings/base.py and mailman_web/settings/mailman.py]
>
> This is very basic Python.
>
>
> > Granted, I am a slow learner, and perhaps already so mixed up after
> reading
> > the myriad HOWTOs for
> > installing MM3 that are available online. I am tempted to say there are
> > many like me who are likely to
> > miss "where to obtain" other settings from.
> >
> > For example, my mind all along has been tuned to having a
> settings_local.py
> > for overriding the settings.py.
> > However, with this particular documentation, it would appear that
> > everything is intended to just go into /etc/mailman3/settings.py.
>
>
> In that method you had the defaults in settings.py which at the end
> imported settings_local.py.
>
> This method has defaults in
> /PATH-TO/mailman_web/settings/{base|mailman}.py and those are imported
> at the beginning of settings.py which then has overrides. This is
> preferable because it allows things in settings.py like
> ```
> HAYSTACK_CONNECTIONS['default']['PATH'] = 'some path'
> ```
> to just override that one thing rather than having to redefine all of
> HAYSTACK_CONNECTIONS or import it from settings in settings_local.py.
>
>
> > Is it possible to modify the documentation to somehow make it obvious
> (in a
> > language that a layman can easily understand,
> > that those two "import *" _DO establish a base set of settings that can
> be
> > augmented or overridden in /etc/mailman3/settings.py_
> > and that those settings are in what file(s) ?
>
>
> Again, this is very basic Python, but if you submit a merge request to
> update
>
> https://gitlab.com/mailman/mailman-suite-doc/-/blob/master/source/install/v…,
>
> we'll certainly consider it.
>
Hi Mark,
Before I wrote this email that you have responded to, I was in the process
of writing another email to you offlist. I kept it in abbeyance.
Now that you have mentioned
https://gitlab.com/mailman/mailman-suite-doc/-/blob/master/source/install/v…,,
please show me how to import it, edit. Then I can submit a diff.
Alternatively, I'd love to be given access to edit that document (and the
edit can be reviewed before getting published) to make it easy to follow by
someone with zero python background.
I am willing to invest some time in improving it for laymen.
--
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: Migrating mailman3 to latest ubuntu lts
by Helio Loureiro
Hi,
Indeed it was the configuration. It was placed into
/etc/mailman3/mailman-web.py. After a I changed to
/etc/mailman3/settings.py a few things advanced a little bit more.
I had to figure out how to fix mysqlclient installation since there isn't a
mention about it and the simple "pip install mysqclient" was breaking with
pkg-config issues. But it did work at the end.
Now I can see further messages on mailman3-web than before.
(venv) mailman@new-server ~ (v3.3.9)> mailman-web migrate
System check identified some issues:
WARNINGS:
account.EmailAddress: (models.W036) MariaDB does not support unique
constraints with conditions.
HINT: A constraint won't be created. Silence this warning if you don't care
about it.
account.EmailAddress: (models.W043) MariaDB does not support indexes on
expressions.
HINT: An index won't be created. Silence this warning if you don't care
about it.
Operations to perform:
Apply all migrations: account, admin, auth, contenttypes,
django_mailman3, django_q, hyperkitty, postorius, sessions, sites,
socialaccount
Running migrations:
Applying account.0004_alter_emailaddress_drop_unique_email...Traceback
(most recent call last):
File
"/local/mailman/venv/lib/python3.10/site-packages/django/db/backends/utils.py",
line 89, in _execute
return self.cursor.execute(sql, params)
File
"/local/mailman/venv/lib/python3.10/site-packages/django/db/backends/mysql/base.py",
line 75, in execute
return self.cursor.execute(query, args)
File
"/local/mailman/venv/lib/python3.10/site-packages/MySQLdb/cursors.py", line
179, in execute
res = self._query(mogrified_query)
File
"/local/mailman/venv/lib/python3.10/site-packages/MySQLdb/cursors.py", line
330, in _query
db.query(q)
File
"/local/mailman/venv/lib/python3.10/site-packages/MySQLdb/connections.py",
line 257, in query
_mysql.connection.query(self, query)
MySQLdb.OperationalError: (2013, 'Lost connection to MySQL server during
query')
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/local/mailman/venv/bin/mailman-web", line 8, in <module>
sys.exit(main())
File
"/local/mailman/venv/lib/python3.10/site-packages/mailman_web/manage.py",
line 90, in main
execute_from_command_line(sys.argv)
File
"/local/mailman/venv/lib/python3.10/site-packages/django/core/management/__init__.py",
line 446, in execute_from_command_line
utility.execute()
File
"/local/mailman/venv/lib/python3.10/site-packages/django/core/management/__init__.py",
line 440, in execute
self.fetch_command(subcommand).run_from_argv(self.argv)
File
"/local/mailman/venv/lib/python3.10/site-packages/django/core/management/base.py",
line 402, in run_from_argv
self.execute(*args, **cmd_options)
File
"/local/mailman/venv/lib/python3.10/site-packages/django/core/management/base.py",
line 448, in execute
output = self.handle(*args, **options)
File
"/local/mailman/venv/lib/python3.10/site-packages/django/core/management/base.py",
line 96, in wrapped
res = handle_func(*args, **kwargs)
File
"/local/mailman/venv/lib/python3.10/site-packages/django/core/management/commands/migrate.py",
line 349, in handle
post_migrate_state = executor.migrate(
File
"/local/mailman/venv/lib/python3.10/site-packages/django/db/migrations/executor.py",
line 135, in migrate
state = self._migrate_all_forwards(
File
"/local/mailman/venv/lib/python3.10/site-packages/django/db/migrations/executor.py",
line 167, in _migrate_all_forwards
state = self.apply_migration(
File
"/local/mailman/venv/lib/python3.10/site-packages/django/db/migrations/executor.py",
line 252, in apply_migration
state = migration.apply(state, schema_editor)
File
"/local/mailman/venv/lib/python3.10/site-packages/django/db/migrations/migration.py",
line 130, in apply
operation.database_forwards(
File
"/local/mailman/venv/lib/python3.10/site-packages/django/db/migrations/operations/fields.py",
line 235, in database_forwards
schema_editor.alter_field(from_model, from_field, to_field)
File
"/local/mailman/venv/lib/python3.10/site-packages/django/db/backends/base/schema.py",
line 788, in alter_field
self._alter_field(
File
"/local/mailman/venv/lib/python3.10/site-packages/django/db/backends/base/schema.py",
line 858, in _alter_field
self.execute(self._delete_unique_sql(model, constraint_name))
File
"/local/mailman/venv/lib/python3.10/site-packages/django/db/backends/base/schema.py",
line 199, in execute
cursor.execute(sql, params)
File
"/local/mailman/venv/lib/python3.10/site-packages/django/db/backends/utils.py",
line 67, in execute
return self._execute_with_wrappers(
File
"/local/mailman/venv/lib/python3.10/site-packages/django/db/backends/utils.py",
line 80, in _execute_with_wrappers
return executor(sql, params, many, context)
File
"/local/mailman/venv/lib/python3.10/site-packages/django/db/backends/utils.py",
line 84, in _execute
with self.db.wrap_database_errors:
File
"/local/mailman/venv/lib/python3.10/site-packages/django/db/utils.py", line
91, in __exit__
raise dj_exc_value.with_traceback(traceback) from exc_value
File
"/local/mailman/venv/lib/python3.10/site-packages/django/db/backends/utils.py",
line 89, in _execute
return self.cursor.execute(sql, params)
File
"/local/mailman/venv/lib/python3.10/site-packages/django/db/backends/mysql/base.py",
line 75, in execute
return self.cursor.execute(query, args)
File
"/local/mailman/venv/lib/python3.10/site-packages/MySQLdb/cursors.py", line
179, in execute
res = self._query(mogrified_query)
File
"/local/mailman/venv/lib/python3.10/site-packages/MySQLdb/cursors.py", line
330, in _query
db.query(q)
File
"/local/mailman/venv/lib/python3.10/site-packages/MySQLdb/connections.py",
line 257, in query
_mysql.connection.query(self, query)
django.db.utils.OperationalError: (2013, 'Lost connection to MySQL server
during query')
Which seems to be complaining with DB credentials. But they're properly
set and it works via mysql command line.
(venv) mailman@new-server ~ (v3.3.9)> mysql -umailman3web -p mailman3web
Enter password:
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A
Welcome to the MariaDB monitor. Commands end with ; or \g.
Your MariaDB connection id is 32
Server version: 10.6.12-MariaDB-0ubuntu0.22.04.1 Ubuntu 22.04
Copyright (c) 2000, 2018, Oracle, MariaDB Corporation Ab and others.
Type 'help;' or '\h' for help. Type '\c' to clear the current input
statement.
MariaDB [mailman3web]> show tables;
+-------------------------------+
| Tables_in_mailman3web |
+-------------------------------+
| account_emailaddress |
| account_emailconfirmation |
| auth_group |
| auth_group_permissions |
| auth_permission |
| auth_user |
| auth_user_groups |
| auth_user_user_permissions |
| django_admin_log |
| django_content_type |
| django_mailman3_maildomain |
| django_mailman3_profile |
| django_migrations |
| django_q_ormq |
| django_q_schedule |
| django_q_task |
| django_session |
| django_site |
| hyperkitty_attachment |
| hyperkitty_email |
| hyperkitty_favorite |
| hyperkitty_lastview |
| hyperkitty_mailinglist |
| hyperkitty_profile |
| hyperkitty_sender |
| hyperkitty_tag |
| hyperkitty_tagging |
| hyperkitty_thread |
| hyperkitty_threadcategory |
| hyperkitty_vote |
| socialaccount_socialaccount |
| socialaccount_socialapp |
| socialaccount_socialapp_sites |
| socialaccount_socialtoken |
+-------------------------------+
34 rows in set (0.000 sec)
On the /etc/mailman3/settings.py:
(venv) mailman@seliius26224 ~ (v3.3.9)> cat /etc/mailman3/settings.py |
grep -v "#" | grep -v '^$'
from mailman_web.settings.base import *
from mailman_web.settings.mailman import *
ADMINS = (
('Mailman Suite Admin', 'root@localhost'),
)
DATABASES = {
'default': {
'ENGINE': 'django.db.backends.mysql',
'NAME': 'mailman3web',
'USER': 'mailman3web',
'PASSWORD': '*******************',
'HOST': 'localhost',
'PORT': '3306',
}
}
STATIC_ROOT = '/local/mailman/web/static'
COMPRESS_ENABLED = True
LOGGING['handlers']['file']['filename'] =
'/local/mailman/web/logs/mailmanweb.log'
ALLOWED_HOSTS = [
"127.0.0.1",
"*"
]
CSRF_TRUSTED_ORIGINS = [
]
SITE_ID = 1
SECRET_KEY = '****************************************'
DEFAULT_FROM_EMAIL = 'admin(a)mailman.domain.com'
SERVER_EMAIL = 'admin(a)mailman.domain.com'
MAILMAN_REST_API_URL = 'http://localhost:8001'
MAILMAN_REST_API_USER = 'restadmin'
MAILMAN_REST_API_PASS = '***************************'
MAILMAN_ARCHIVER_KEY = '****************************'
MAILMAN_ARCHIVER_FROM = ('127.0.0.1', '::1', '1.2.3.4')
HAYSTACK_CONNECTIONS = {
'default': {
'PATH': "/opt/mailman/web/xapian_index",
'ENGINE': 'xapian_backend.XapianEngine'
},
}
And /local/mailman/web/logs/mailmanweb.log is empty.
Best Regards,
Helio Loureiro
https://helio.loureiro.eng.br
https://github.com/helioloureiro
https://mastodon.social/@helioloureiro
On Sun, 17 Dec 2023 at 16:35, Mark Sapiro <mark(a)msapiro.net> wrote:
> On 12/16/23 10:12 AM, Helio Loureiro wrote:
> > Hi,
> >
> > Well... not that good. Now it is mailman3-web that doesn't work.
> >
> > mailman@new-machine ~ (v3.3.9)> source venv/bin/activate.fish
> > (venv) mailman@new-machine ~ (v3.3.9)> mailman-web
> >
> > Type 'mailman-web help <subcommand>' for help on a specific subcommand.
> >
> > Available subcommands:
> >
> > [django]
> > check
> > compilemessages
> > createcachetable
> > dbshell
> > diffsettings
> > dumpdata
> > flush
> > inspectdb
> > loaddata
> > makemessages
> > makemigrations
> > migrate
> > optimizemigration
> > runserver
> > sendtestemail
> > shell
> > showmigrations
> > sqlflush
> > sqlmigrate
> > sqlsequencereset
> > squashmigrations
> > startapp
> > startproject
> > test
> > testserver
>
> This response indicates that `mailman-web` is not getting settings.py.
> Have you configured /etc/mailman3/settings.py? See
> <
> https://docs.mailman3.org/en/latest/install/virtualenv.html#initial-configu…
> >.
>
> > (venv) mailman@new-machine ~ (v3.3.9)> mailman-web check
> > System check identified no issues (0 silenced).
> > (venv) mailman@new-machine ~ (v3.3.9)> mailman-web check migrate
>
> You should run `mailman-web migrate` not `mailman-web check migrate`
> plus others. See
> <
> https://docs.mailman3.org/en/latest/install/virtualenv.html#run-database-mi…>
>
> et.seq. but first you need the appropriate settings so `mailman-web`
> returns something like
> ```
> $ mailman-web
>
> Type 'mailman-web help <subcommand>' for help on a specific subcommand.
>
> Available subcommands:
>
> [account]
> account_unsetmultipleprimaryemails
>
> [auth]
> changepassword
> createsuperuser
>
> [compressor]
> compress
> mtime_cache
>
> [contenttypes]
> remove_stale_contenttypes
>
> [django]
> check
> compilemessages
> createcachetable
> dbshell
> diffsettings
> dumpdata
> flush
> inspectdb
> loaddata
> makemessages
> makemigrations
> migrate
> optimizemigration
> sendtestemail
> shell
> showmigrations
> sqlflush
> sqlmigrate
> sqlsequencereset
> squashmigrations
> startapp
> startproject
> test
> testserver
>
> [django_extensions]
> admin_generator
> clean_pyc
> clear_cache
> compile_pyc
> create_command
> create_jobs
> create_template_tags
> delete_squashed_migrations
> describe_form
> drop_test_database
> dumpscript
> export_emails
> find_template
> generate_password
> generate_secret_key
> graph_models
> list_model_info
> list_signals
> mail_debug
> managestate
> merge_model_instances
> notes
> pipchecker
> print_settings
> print_user_for_session
> raise_test_exception
> reset_db
> reset_schema
> runjob
> runjobs
> runprofileserver
> runscript
> runserver_plus
> set_default_site
> set_fake_emails
> set_fake_passwords
> shell_plus
> show_template_tags
> show_urls
> sqlcreate
> sqldiff
> sqldsn
> sync_s3
> syncdata
> unreferenced_files
> update_permissions
> validate_templates
>
> [django_q]
> qcluster
> qinfo
> qmemory
> qmonitor
>
> [haystack]
> build_solr_schema
> clear_index
> haystack_info
> rebuild_index
> update_index
>
> [hyperkitty]
> attachments_to_file
> hyperkitty_import
> hyperkitty_warm_up_cache
> mailman_sync
> update_index_one_list
>
> [postorius]
> mmclient
> reset_passwords
>
> [rest_framework]
> generateschema
>
> [sessions]
> clearsessions
>
> [staticfiles]
> collectstatic
> findstatic
> runserver
> ```
>
>
> --
> 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 helio(a)loureiro.eng.br
>
1 year, 5 months

[MM3-users] Re: Apache+mod_wsgi issue
by Odhiambo Washington
On Thu, Dec 22, 2022 at 8:02 PM Mark Sapiro <mark(a)msapiro.net> wrote:
> On 12/22/22 03:49, Odhiambo Washington wrote:
> >
> > My challenge now is to get Apache+mod_uwsgi to serve my pages,
>
> I assume that's a typo. I.e, mod_wsgi, not mod_uwsgi.
>
That's right :)
> > but I am hitting the error below which has gotten me stuck.
> > Thanking you in advance for your advice on how to overcome this.
> >
> ...> [Thu Dec 22 14:21:23.041064 2022] [wsgi:error] [pid 4288] [remote
> > 197.232.81.246:15107] ModuleNotFoundError: No module named 'settings'
>
>
> Django can't import your settings.py. Is the directory that contains it
> in your Python path and does that directory contain (an empty) __init__.py?
>
Here is the VHOST...
<CUT> vhost ---8<
[00:53 mm ]$ less /usr/local/etc/apache24/Includes/mailman3-uwsgi.cf
# mm3-lists.kictanet.or.ke
<VirtualHost *:80>
ServerName mm3-lists.kictanet.or.ke
ServerAdmin odhiambo(a)gmail.com
Redirect permanent / https://mm3-lists.kictanet.or.ke
</VirtualHost>
# This goes in a global section.
WSGIDaemonProcess mailman-web display-name=mailman-web
maximum-requests=1000 umask=0002 user=mailman group=mailman
python-path=/opt/mailman/mm/venv/lib/python3.9/site-packages:/opt/mailman/mm/venv/lib/python3.9
python-home=/opt/mailman/mm/venv home=/opt/mailman/mm/var
WSGIRestrictSignal Off
<VirtualHost *:443>
ServerName mm3-lists.kictanet.or.ke
ServerAdmin odhiambo(a)gmail.com
SSLEngine on
SSLCipherSuite
ALL:!ADH:!EXPORT56:RC4+RSA:+HIGH:+MEDIUM:+LOW:+SSLv2:+EXP:+eNULL
SSLCertificateFile "/usr/local/etc/letsencrypt/live/
mm3-lists.kictanet.or.ke/cert.pem"
SSLCertificateKeyFile "/usr/local/etc/letsencrypt/live/
mm3-lists.kictanet.or.ke/privkey.pem"
SSLCertificateChainFile "/usr/local/etc/letsencrypt/live/
mm3-lists.kictanet.or.ke/chain.pem"
CustomLog /var/log/mm3-lists-access.log combined
ErrorLog /var/log/mm3-lists-error.log
LogLevel info
Alias /favicon.ico /opt/mailman/mm/static/hyperkitty/img/favicon.ico
# (I'm not sure that WSGIRestrictSignal Off is required, but it was in the
# provided example so I kept it. I also made changes to WSGIDaemonProcess
# based on my own mod_wsgi experience elsewhere.)
# This goes in the VirtualHost block for the domain.
# Mailman 3 stuff
Alias /static "/opt/mailman/mm/static"
<Directory "/opt/mailman/mm/static">
Require all granted
</Directory>
WSGIScriptAlias /mailman3 /opt/mailman/mm/wsgi.py
<Directory "/opt/mailman/mm/">
<Files wsgi.py>
Order deny,allow
Allow from all
Require all granted
</Files>
WSGIProcessGroup mailman-web
</Directory>
</VirtualHost>
</CUT>
And here is the path - or maybe there is something I am missing in the
VHOST?
[00:53 ~ ]$ cd /opt/mailman/mm/
[00:53 mm ]$ ls -al
total 116
drwxr-xr-x 9 mailman mailman 512 Dec 22 13:54 .
drwxr-xr-x 6 mailman mailman 512 Dec 21 07:54 ..
-rw-r--r-- 1 mailman mailman 0 Sep 29 2021 __init__.py
drwxr-xr-x 2 mailman mailman 512 Dec 22 14:18 __pycache__
-rw-r--r-- 1 mailman mailman 15574 Dec 20 18:16 _settings.py
drwxr-xr-x 3 mailman mailman 512 Dec 20 19:47 bin
drwxr-xr-x 5 mailman mailman 512 Dec 8 10:32 etc
drwxr-xr-x 2 mailman mailman 1536 Dec 21 11:54 fulltext_index
-rw-r--r-- 1 mailman mailman 317 Dec 21 16:53 gunicorn.conf
lrwxr-xr-x 1 mailman mailman 13 Dec 21 16:55 gunicorn.conf.py ->
gunicorn.conf
-rw-r--r-- 1 mailman mailman 0 Dec 5 18:10 init.py
lrwxr-xr-x 1 mailman mailman 24 Dec 5 17:38 logs ->
/opt/mailman/mm/var/logs
-rw-r--r-- 1 mailman mailman 592 Oct 2 2021 mailman-crontab
-rw-r--r-- 1 mailman mailman 409 Dec 20 16:32 mailman-hyperkitty.cfg
-rw-r--r-- 1 mailman mailman 1330 Dec 20 16:24 mailman.cfg
-rw-r--r-- 1 mailman mailman 183 Dec 2 15:17 main.py
-rwxr-xr-x 1 mailman mailman 243 Sep 29 2021 manage.py
-rw-r--r-- 1 mailman mailman 510 Dec 11 14:11 modify-db.sql
-rw-r--r-- 1 mailman mailman 15844 Dec 22 14:18 settings.py
-rw-r--r-- 1 mailman mailman 6622 Dec 22 11:27 settings_local.py
drwxr-xr-x 10 mailman mailman 512 Dec 5 17:38 static
-rw-r--r-- 1 mailman mailman 1453 Dec 20 16:32 urls.py
-rw-r--r-- 1 mailman mailman 1266 Dec 22 13:55 uwsgi.ini
drwxr-xr-x 12 mailman mailman 512 Dec 22 14:21 var
drwxr-xr-x 7 mailman mailman 512 Dec 6 15:35 venv
-rw-r--r-- 1 mailman mailman 1173 Sep 29 2021 wsgi.py
--
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: Post-installation documentation?
by David Newman
On 11/24/21 2:36 PM, Mark Sapiro wrote:
> On 11/24/21 9:40 AM, David Newman wrote:
>>
>> IMO post-installation docs for list admins would be a big help in
>> Mailman3 adoption. I'm willing to help with this.
>
>
> Thank you for being willing to contribute. I think the place for list
> admin docs would be in the https://gitlab.com/mailman/mailman-suite-doc
> project which is the source for https://docs.mailman3.org/en/latest/.
> There is currently a userguide there at source/userguide.rst and
> referenced from source/index.rst. the addition of an adminguide.rst
> would be welcom if you want to work on that.
Thanks, will get into this ASAP. Am happy to contribute once I acquire a
bit more clue.
>
>
>> When I say "working": I'm looking to migrate Mailman2 mailing lists to
>> Mailman3, but am struggling with even basic setup tasks before we
>> attempt list migtration.
>>
>> For example, on admin page I've set up two lists, one public and one
>> private (each with unique list IDs), but neither appear in the site's
>> list index.
>
>
> Here are the steps to migrate a 2.1 list named `alist(a)example.com` and
> its archives.
>
> run Mailman's `bin/mailman create alist(a)example.com`
>
> follow that with
> ```
> bin/mailman import21 alist(a)example.com
> /path/to/mailman2.1/lists/alist/config.pck
> ```
> That will create the list and import its members and settings.
>
> To import archives run the Django admin command with arguments
> ```
> hyperkitty_import -l alist(a)example.com
> /path/to/mailman2.1/archives/private/alist.mbox/alist.mbox
Good up to here, but ... hyperkitty_import not found.
This wasn't covered in the venv docs:
https://docs.mailman3.org/en/latest/install/virtualenv.html
or in the web frontend docs [1]:
https://docs.mailman3.org/en/latest/config-web.html
or in the howto Brian Carpenter (RIP) wrote for Debian 10:
https://wiki.list.org/DOC/Howto_Install_Mailman3_On_Debian10
Also, I had previously created two other lists under the site admin
page. These do not appear in the site's mailing lists page, nor does the
list I successfully imported from MM 2.1 appear in the admin page, under
mailing lists.
> ```
>
>> And I don't know where to add list members.
>
>
> For imported lists, they are already added, but for new lists, you can
> add them in Postorius under Mass operations -> Mass subscribe or via the
> bin/mailman commands `addmembers` or `syncmembers`. See
> https://docs.mailman3.org/projects/mailman/en/latest/src/mailman/commands/d…
>
>
>
>> And clicking the site archives link throws this error:
>>
>> django.urls.exceptions.NoReverseMatch: Reverse for 'hk_list_overview'
>> with keyword arguments '{'mlist_fqdn': 'wheee'}' not found. 1
>> pattern(s) tried: ['archives/list/(?P<mlist_fqdn>[^/@]+@[^/@]+)/$']
>
>
> Did you specify the list's fqdn as in
> https://www.example.com/archives/list/list@example.com/
No. I clicked the archives icon at the top of a Postorious page. This is
possibly related to the hyperkitty_import issue above.
Thanks again.
dn
[1] In addition to the web frontend docs, there is also a hyperkitty
docs page:
https://docs.mailman3.org/projects/hyperkitty/en/latest/install.html
I found this page unhelpful. For example it starts with this command:
sudo python setup.py install
but doesn't say where setup.py resides, or which directory the command
should be run from. (And yes, different OSs use different locations. I'd
setting for one being named, along with a YMMV disclaimer.)
Then this doc goes to database setup, with this example:
django-admin migrate --pythonpath example_project --settings settings
Again, this is unclear. I don't know what "example_project" is, or in
what context it's used here.
This doc also describes a different, and less straightforward,
import-from-2.1 procedure than Mark described above.
It's possible the hyperkitty doc is now outdated. I'd be glad to help
bring the various different install guides together and update them --
once I better understand how they work. Thanks.
3 years, 6 months

[MM3-users] Re: hyperkitty threads by month question
by Bryan Fields
On 7/26/24 4:01 PM, Mark Sapiro wrote:
> Yes, I suspect this bad date is part of the issue.
>
> I would do a few things. First,
>
> SELECT message_id FROM hyperkitty_email WHERE thread_id = 35670;
mailmanweb=> SELECT message_id FROM hyperkitty_email WHERE thread_id = 35670;
message_id
-------------------------------------
200204151506953.SM01412(a)sunchar.com
Yep, that matches the bad date message ID.
> If this returns just the one message_id, I would then
>
> DELETE FROM hyperkitty_thread WHERE id = 35670;
> DELETE FROM hyperkitty_email WHERE id = 150555;
It's giving an error due to a fk constraint on another table. I'm not
familiar with the db structure enough to be certain how to clean/fix it.
mailmanweb=> DELETE FROM hyperkitty_thread WHERE id = 35670;
ERROR: update or delete on table "hyperkitty_thread" violates foreign key constraint "hyperkitty_lastview_thread_id_5bd4f0ad_fk_hyperkitty_thread_id" on table "hyperkitty_lastview"
DETAIL: Key (id)=(35670) is still referenced from table "hyperkitty_lastview".
mailmanweb=> DELETE FROM hyperkitty_email WHERE id = 150555;
ERROR: update or delete on table "hyperkitty_email" violates foreign key constraint "hyperkitty_thread_starting_email_id_fa7c55f5_fk_hyperkitt" on table "hyperkitty_thread"
DETAIL: Key (id)=(150555) is still referenced from table "hyperkitty_thread".
> and see if that fixes the internal server error when accessing the
> archive. I would also
>
> SELECT * FROM hyperkitty_email WHERE id = 136872;
mailmanweb=> SELECT * FROM hyperkitty_email WHERE id = 136872;
id | message_id | message_id_hash | subject | content | date | timezone | in_reply_to | archived_date | thread_depth | thread_order | mailinglist_id | parent_id | sender_id | thread_id | sender_name
--------+------------------------------------------+----------------------------------+------------------+-------------------------------------------------------------------+------------------------+----------+-------------+------------------------+--------------+--------------+----------------+-----------+-------------------------+-----------+---------------
136872 | 200001010102.BAA05112(a)genesis.domino.org | SGZJVBCSRYSHGHR4BB2632INFGYWOJYH | UK GMT roll over | +| 0100-01-01 01:02:34+00 | 0 | | 1999-12-31 20:20:13+00 | 0 | 0 | 3 | | neil(a)genesis.domino.org | 31067 | Neil J. McRae
| | | | GMT and CET rolled over without any major incidents. The cellular+| | | | | | | | | | |
| | | | networks were busy but thats to be expected. +| | | | | | | | | | |
| | | | +| | | | | | | | | | |
| | | | Regards, +| | | | | | | | | | |
| | | | Neil. +| | | | | | | | | | |
| | | | -- +| | | | | | | | | | |
| | | | Neil J. McRae - Alive and Kicking. +| | | | | | | | | | |
| | | | neil(a)DOMINO.ORG +| | | | | | | | | | |
| | | | +| | | | | | | | | | |
| | | | | | | | | | | | | | |
That message had "Date: Sat, 1 Jan 100 01:02:34 +0000 (GMT)" in the mbox.
It looks like it should be year 2000 from the rest of the headers
This message was found by your script too:
Date: changed at line 13785764
Date: Sat, 1 Jan 100 01:02:34 +0000 (GMT)
Date: Fri, 31 Dec 1999 20:20:13 -0000
> and maybe update the `date` in that entry.
I'm actually thinking I need to fix the archive mbox, then delete them and
re-import them once they are cleaned.
> Also, FYI, assuming those messages with very old Date: headers had
> reasonable unix from dates, the hyperkitty/contrib/cleanarch3 script
> would fix them, except you have to get the script from
> https://gitlab.com/mailman/hyperkitty/-/blob/master/hyperkitty/contrib/clea…
> or https://www.msapiro.net/scripts/cleanarch3 because the script in the
> latest release has a bug.
I tried the dry run option on your script and it gave a bunch of output for bad
dates. This was absent on the one shipping with the source. What's interesting
is that pipermail seems to have no issue with this, detecting the date
correctly.
https://mailman.nanog.org/pipermail/nanog/2000-January/137630.html
One other thing, I did notice a number of archives not showing up in sequence
due to missing "In-Reply-To:" headers from the source. The first message in
this is one like this, and pipermail in mmm2 seems to handle this by referencing
the subject, https://mailman.nanog.org/pipermail/nanog/2002-April/151325.html,
where as in hyperkitty it's an orphaned thread.
Is the archive tool in pipermail's import more robust in this manner? I'd argue
it's common to have missing In-Reply-To: headers where the subject and time
would need to be used to infer the likely thread. I'll agree this is a major
violation of the relevant RFC's to be missing this, but many MUA's (M$) are
famous for doing just this.
Thank you,
--
Bryan Fields
727-409-1194 - Voice
http://bryanfields.net
10 months, 1 week

[MM3-users] Re: Database permission problem?
by Bill Oliver
On Tue, 2024-10-15 at 17:13 -0700, Mark Sapiro wrote:
> On 10/15/24 15:24, Bill Oliver wrote:
> >
> > Yeah, I saw that, too. The double db files are created by
> > postmap. I
> > haven't worried about it too much yet, since the permissions are
> > the
> > same. I don't know why postmap does this, but it's next on my
> > list of
> > things to fix.
>
>
> You should not be running postmap manually and never on a *.db file
> in
> any case. Mailman should be creating postfix_domains, postfix_lmtp
> and
> postfix_vmap and calling postmap on those to create the .db files.
>
> > In my main.cf postfix_lmtp is mentioned four times:
> >
> > virtual_mailbox_maps =
> > proxy:mysql:/etc/postfix/sql/mysql_virtual_mailbox_maps.cf,
> >
> > proxy:mysql:/etc/postfix/sql/mysql_virtual_alias_domain_mailbox_map
> > s.cf
> > #added 20241009 for mailman
> > hash:/opt/mailman/mm/var/data/postfix_lmtp ${dovecot}
> >
> > virtual_alias_maps =
> > proxy:mysql:/etc/postfix/sql/mysql_virtual_alias_maps.cf,
> >
> > proxy:mysql:/etc/postfix/sql/mysql_virtual_alias_domain_maps.cf,
> >
> > proxy:mysql:/etc/postfix/sql/mysql_virtual_alias_domain_catchall_ma
> > ps.c
> > f
> > #added 20241009 for mailman
> > hash:/opt/mailman/mm/var/data/postfix_vmap
> >
> > #Mailman transport stuff
> > transport_maps =
> > hash:/opt/mailman/mm/var/data/postfix_lmtp
> > local_recipient_maps =
> > hash:/opt/mailman/mm/var/data/postfix_lmtp ${dovecot}
>
>
> Are you adding ${dovecot} to the local_recipient_maps and
> virtual_mailbox_maps mailman entries or was that there before?
Thanks. The reason I created them by hand is that they are not being
created automatically it seemed. If I remove them and restart things, I
get the following errors in /var/log/mail.err:
2024-10-15T12:43:31.060478-04:00 mail postfix/smtpd[961837]: error:
open database /opt/mailman/mm/var/data/postfix_domains.db: No such file
or directory
2024-10-15T12:43:31.060874-04:00 mail postfix/smtpd[961837]: error:
open database /opt/mailman/mm/var/data/postfix_lmtp.db: No such file or
directory
2024-10-15T12:43:31.069450-04:00 mail postfix/smtpd[961837]: error:
open database /opt/mailman/mm/var/data/postfix_vmap.db: No such file or
directory
However.... I just looked at the /opt/mailman/mm/var/data directory and
the (single) db files are now there, and that error occurs only once.
So, I probably over-reacted to it.
Unfortunately, I'm back to the permission declined error:
2024-10-15T22:31:31.973125-04:00 mail postfix/virtual[3497]: error:
open database /opt/mailman/mm/var/data/postfix_lmtp.db: Permission
denied
As far as the addition of ${dovecot} goes, I did it myself because of
the instructions at:
https://docs.mailman3.org/projects/mailman/en/latest/src/mailman/docs/mta.h…
Dovecot is having a hard time authenticating mailinglist users. I
figured that problem arose because it can't use any of the mailman .db
files, but I don't know. In any case, a dovecot error message that
happens when a user (who has an account on the local machine) sends
mail to the mailing list includes:
2024-10-15T21:50:45.231465-04:00 mail dovecot: auth-worker(5669):
Debug: conn unix:auth-worker (pid=3690,uid=111): auth-worker<1>:
pam(oliver(a)billoblog.com,129.222.252.225): lookup service=dovecot
2024-10-15T21:50:45.234036-04:00 mail dovecot: auth-worker(5669):
Debug: conn unix:auth-worker (pid=3690,uid=111): auth-worker<1>:
pam(oliver(a)billoblog.com,129.222.252.225): #1/1 style=1 msg=Password:
2024-10-15T21:50:46.716360-04:00 mail dovecot: auth-worker(5669): conn
unix:auth-worker (pid=3690,uid=111): auth-worker<1>:
pam(oliver(a)billoblog.com,129.222.252.225): pam_authenticate() failed:
Authentication failure (Password mismatch?) (given password: XXXXXXX)
2024-10-15T21:50:46.716497-04:00 mail dovecot: auth-worker(5669):
Debug: conn unix:auth-worker (pid=3690,uid=111): auth-worker<1>:
pam(oliver(a)billoblog.com,129.222.252.225): Finished passdb lookup
2024-10-15T21:50:46.716562-04:00 mail dovecot: auth-worker(5669):
Debug: conn unix:auth-worker (pid=3690,uid=111): auth-worker<1>:
Finished: password_mismatch
It should be noted that mail works fine for that user, and this error
arises *only* when mail is sent to the mailinglist address. Dovecot
does not complain if I send mail elsewhere. Mail is received and
delivered to and from this address without a problem.
The other thing I did was add an alias domain when I set up the domain
in postorius, again because it seemed from reading the instructions
that this was advisable on a server with multiple virtual domains.
Thanks.
7 months, 3 weeks

[MM3-users] Re: The doubled entries issue
by Lars Bjørndal
Hi!
The problem seesm to be solved. Anyway, here's the answer to questions:
On Sun, Nov 12, 2023 at 08:07:59AM -0800, Mark Sapiro wrote:
> On 11/11/23 23:56, Lars Bjørndal wrote:
> >
> > Thank you. The script I try to run, is found here: https://gitlab.com/mailman/mailman/-/issues/657
> >
> > I named the script fix-doubled-entries.py. When I try
> >
> > `mailman shell --run ./fix-doubled-entries.py` I get:
>
> This is not the way to run a script with `mailman shell`. See
> ```
> mailman shell --details
> ```
> for info. However, that script cannot be run as is by `mailman shell --run`.
> It can be run by invoking `mailman shell` interactively and copying and
> pasting it,
Yes, that worked, e.g. no error messages.
> or if your Mailman is installed in a venv it can be run with the
> venv active by `python ./fix-doubled-entries.py`.
I have mailman installed in venv, but got the following when trying that:
"python fix-doubled-entries.py" need the IListManager interface but can't find it.
> However, that script will not fix your issue because you don't have multiple
> mhonarc entries for a list. See https://lists.mailman3.org/archives/list/mailman-users@mailman3.org/message…
> and as it says, Tell us more about the "duplicate entries" error, and if
> possible copy it exactly from where you found it originally, including any
> traceback.
Here's the entries in the mailman.log file:
[11/Nov/2023:09:18:41 +0100] "GET /3.1/addresses/lars(a)lamasti.net HTTP/1.1" 200 365 "-" "GNU Mailman REST client v3.3.5"
[11/Nov/2023:09:18:42 +0100] "GET /3.1/lists/annonsering.hodr.no/roster/moderator HTTP/1.1" 200 90 "-" "GNU Mailman REST client v3.3.5"
Nov 11 09:18:43 2023 (1709) HyperKitty archived message <m3sf5cd7ok.fsf(a)dalen.lamasti.net> to https://hodr.no/archives/list/annonsering@hodr.no/message/NL5LTYANYLKOF5N33…
[11/Nov/2023:09:18:44 +0100] "GET /3.1/users/lars(a)lamasti.net HTTP/1.1" 200 259 "-" "GNU Mailman REST client v3.3.5"
Nov 11 09:18:47 2023 (1715) Uncaught runner exception: Multiple rows were found when one or none was required
Nov 11 09:18:47 2023 (1715) Traceback (most recent call last):
File "/opt/mailman3/venv/lib64/python3.11/site-packages/mailman/core/runner.py", line 179, in _one_iteration
self._process_one_file(msg, msgdata)
File "/opt/mailman3/venv/lib64/python3.11/site-packages/mailman/core/runner.py", line 272, in _process_one_file
keepqueued = self._dispose(mlist, msg, msgdata)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/mailman3/venv/lib64/python3.11/site-packages/mailman/runners/outgoing.py", line 111, in _dispose
self._func(mlist, msg, msgdata)
File "/opt/mailman3/venv/lib64/python3.11/site-packages/mailman/mta/deliver.py", line 89, in deliver
refused = agent.deliver(mlist, msg, msgdata)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/mailman3/venv/lib64/python3.11/site-packages/mailman/mta/base.py", line 167, in deliver
callback(mlist, message_copy, msgdata_copy)
File "/opt/mailman3/venv/lib64/python3.11/site-packages/mailman/mta/decorating.py", line 32, in decorate
decorator.process(mlist, msg, msgdata)
File "/opt/mailman3/venv/lib64/python3.11/site-packages/mailman/handlers/decorate.py", line 250, in process
process(mlist, msg, msgdata)
File "/opt/mailman3/venv/lib64/python3.11/site-packages/mailman/handlers/decorate.py", line 73, in process
for archiver in IListArchiverSet(mlist).archivers:
^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/mailman3/venv/lib64/python3.11/site-packages/zope/component/_api.py", line 167, in adapter_hook
return sitemanager.queryAdapter(object, interface, name, default)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/mailman3/venv/lib64/python3.11/site-packages/zope/interface/registry.py", line 351, in queryAdapter
return self.adapters.queryAdapter(object, interface, name, default)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/mailman3/venv/lib64/python3.11/site-packages/mailman/database/transaction.py", line 106, in wrapper
return function(args[0], config.db.store, *args[1:], **kws)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/mailman3/venv/lib64/python3.11/site-packages/mailman/model/mailinglist.py", line 653, in __init__
ListArchiver.name == archiver_name).one_or_none()
^^^^^^^^^^^^^
File "/opt/mailman3/venv/lib64/python3.11/site-packages/sqlalchemy/orm/query.py", line 2769, in one_or_none
return self._iter().one_or_none() # type: ignore
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/mailman3/venv/lib64/python3.11/site-packages/sqlalchemy/engine/result.py", line 1813, in one_or_none
return self._only_one_row(
^^^^^^^^^^^^^^^^^^^
File "/opt/mailman3/venv/lib64/python3.11/site-packages/sqlalchemy/engine/result.py", line 816, in _only_one_row
raise exc.MultipleResultsFound(
sqlalchemy.exc.MultipleResultsFound: Multiple rows were found when one or none was required
Nov 11 09:18:47 2023 (1715) SHUNTING: 1699690727.810848+3b6f3baba5576f3d87d3ff392aba2715d4dda793
[11/Nov/2023:10:00:02 +0100] "GET /3.1/lists?count=10&page=1 HTTP/1.1" 200 4061 "-" "GNU Mailman REST client v3.3.5"
I don't know what fixed the problem, but when I did `mailman unshunt` the message went through.
Will mailman notify when there's shunted messages?
Lars
1 year, 6 months

[MM3-users] Re: A little stuck with installation of MM3 - ModuleNotFoundError: No module named 'flufl.lock'
by Odhiambo Washington
On Sun, 26 Jul 2020 at 18:48, Mark Sapiro <mark(a)msapiro.net> wrote:
> On 7/26/20 3:15 AM, Odhiambo Washington wrote:
>
> > There is still some confusion on my part about the directives in the file
> > so allow me to seek some clarifications.
> >
> > The following are the contents of a file I have created and placed in my
> > Apache Includes/ directory.
> > I was hoping that with it, I can now access http://lists.my.server/mm3
> and
> > get the UI.
> >
> > <CUT>
> >
> > # Global section
> > 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
> > WSGIRestrictSignal Off
> >
> > <VirtualHost *:80>
> > ServerName lists.my.server
> > ServerAdmin odhiambo(a)gmail.com
> >
> > # (I'm not sure that WSGIRestrictSignal Off is required, but it was in
> the
> > # provided example so I kept it. I also made changes to WSGIDaemonProcess
> > # based on my own mod_wsgi experience elsewhere.)
> >
> > ErrorLog /var/log/myserver-error.log
> > LogLevel debug
> >
> > # This goes in the VirtualHost block for the domain.
> >
> > # Mailman 3 stuff
> > Alias /static "/var/spool/mailman-web/static" *<----- Where is this
> > directory supposed to be and what/who creates it and with what
> permissions?*
>
>
> It is created/updated by the mailman-post-update script based on CONFDIR
> and STATIC_DIR.
>
The fact that I have run the mailman-post-update script and these
directories aren't created means there is a problem in my setup, yes?
> > <Directory "/var/spool/mailman-web/static">
>
> With the settings in the sample, the above should be
>
> <Directory "/opt/mailman/mm/static">
>
> and the alias
>
> Alias /static "/opt/mailman/mm/static"
>
> Clearly
> <
> https://wiki.list.org/DOC/Mailman%203%20installation%20experience?action=At…
> >
> doesn't match some other files. I'll review abd update that.
>
Okay. I am anxiously waiting.
>
> > Require all granted
> > </Directory>
> > WSGIScriptAlias /mm3 /opt/mailman/mm/wsgi.py
> > <Directory "/opt/mailman/mm/">
> > <Files wsgi.py>
> > Order deny,allow
> > Allow from all
> > Require all granted
> > </Files>
> > WSGIProcessGroup mailman-web
> > </Directory>
> > </VirtualHost>
> >
> > </CUT-HERE>
> >
> > I end up with an "Internal server error" and from the error log I see:
> >
> ...
> > [Sun Jul 26 12:04:44.093265 2020] [wsgi:error] [pid 6444] [remote
> > 197.232.81.246:53383] ModuleNotFoundError: No module named 'settings'
>
>
> Django is trying to import your settings.py file and can't find it. Is
> it at /opt/mailman/mm/settings.py and also local settings at
> /opt/mailman/mm/settings_local.py?
Yes, I have these files:
(venv) [root@gw /opt/mailman/mm]# ls -al /opt/mailman/mm/settings*
-rw-r--r-- 1 mailman3 wheel 15518 Jul 25 14:34
/opt/mailman/mm/settings.py
-rw-r--r-- 1 mailman3 wheel 15773 Jul 26 10:33
/opt/mailman/mm/settings_local.py
PS: I made my /opt/mailman to be owned by mailman3:wheel because of a
confusion with the instructions at some point in the reading
of some documentation previously (in my previous attempt last year!) and
had noted that in my NOTES. I'll change this once things get clear for me.
Also, the fact that one of the init scripts
<https://wiki.list.org/DOC/Mailman%203%20installation%20experience?action=At…>
in your "reflection" page was calling sudo :)
--
Best regards,
Odhiambo WASHINGTON,
Nairobi,KE
+254 7 3200 0004/+254 7 2274 3223
"Oh, the cruft.", grep ^[^#] :-)
4 years, 10 months

[MM3-users] Re: SPF check fails for lists subdomain
by Jan Eden
On 2023-01-04 15:07, Mark Sapiro wrote:
> On 1/4/23 14:02, Jan Eden via Mailman-users wrote:
> > 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.
>
> As I said at <https://lists.mailman3.org/archives/list/mailman-users@mailman3.org/message…>
> I was misreading your DNS and now I am as puzzled as you about the failure.
It gets even more mysterious. I tried sending messages from both
lists.eden.one and janeden.net (my other domain) to a gmail account and
to another mail provider. Both messages passed the SPF checks on both
services (s. the relevant headers quoted below). Now because I send
those messages via my SMTP user (smtpuser(a)eden.one) and use SRS, the SPF
check operates (and succeeds) on e.g.
srs0=jdm+=5c=lists.eden.one=testlist-bounces+gmailuser=googlemail.com(a)eden.one
(and not on somethingsomething(a)lists.eden.one or
somethingsomething(a)janeden.net) Could this be the reason for the failed
SPF checks in Yahoo's and Google's DMARC reports?
- Jan
==============================
Authentication-Results: posteo.de; dmarc=pass (p=quarantine dis=none) header.from=lists.eden.one
Authentication-Results: posteo.de; spf=pass smtp.mailfrom=eden.one
Authentication-Results: posteo.de;
dkim=pass (2048-bit key) header.d=lists.eden.one header.i=(a)lists.eden.one header.b=8FtNB1m3;
dkim-atps=neutral
------------------------------
Delivered-To: gmailuser(a)gmail.com
Received: by 2002:a05:7022:4584:b0:4b:2a9c:6c6f with SMTP id cf4csp83532dlb;
Wed, 4 Jan 2023 23:29:12 -0800 (PST)
ARC-Authentication-Results: i=1; mx.google.com;
dkim=pass header.i=(a)lists.eden.one header.s=s42 header.b=lrjRRPic;
spf=pass (google.com: domain of srs0=jdm+=5c=lists.eden.one=testlist-bounces+gmailuser=googlemail.com(a)eden.one designates 123.123.123.123 as permitted sender) smtp.mailfrom="SRS0=JDm+=5C=lists.eden.one=testlist-bounces+gmailuser=googlemail.com(a)eden.one";
dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=lists.eden.one
Received-SPF: pass (google.com: domain of srs0=jdm+=5c=lists.eden.one=testlist-bounces+gmailuser=googlemail.com(a)eden.one designates 123.123.123.123 as permitted sender) client-ip=123.123.123.123;
Authentication-Results: mx.google.com;
dkim=pass header.i=(a)lists.eden.one header.s=s42 header.b=lrjRRPic;
spf=pass (google.com: domain of srs0=jdm+=5c=lists.eden.one=testlist-bounces+gmailuser=googlemail.com(a)eden.one designates 123.123.123.123 as permitted sender) smtp.mailfrom="SRS0=JDm+=5C=lists.eden.one=testlist-bounces+gmailuser=googlemail.com(a)eden.one";
dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=lists.eden.one
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=lists.eden.one; s=s42; t=1672903751; h=from:from:reply-to:reply-to:subject:subject:date:date:
message-id:message-id:to:to:cc:mime-version:mime-version:
content-type:content-type:list-id:list-help:list-owner:
list-unsubscribe:list-subscribe:list-post; bh=q4JtVWzFRbBZ12C26k1xKRRVOBGue+2uV43xiHohi3M=; b=lrjRRPicpiyGUP11wjj76yIg8qHib1aUAS99+RNhSwYE9HzXctedXbdMXeY7WJyUc1gE2Z PFkDPZD6YMGIAY9N35fzgzoMgrgNAWkTLqDF7i5d0kEXEhEuQ+hLbRHKMcsD8XDVff41iY vLnygg85AKj5L4dvq/p5o4TEjmfaXHadRJ6ZI6qY67Yys1D+LqZzbfIQyvgUH+U986d0Ed SO3POUWJLcYNwwQk0UzTc4iIenM7042alew/wXoncDc1lnMQrAYHY/lPwGHFyqqyPebkLZ bE3nM4g8pM9ODXBbn0Vs7602SzCFkHs2l1QScFtV9+pZbPaKgYL5TW6Q8BT0MA==
Received: from client.eden.one (unknown [195.37.242.24]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)
Date: Thu, 5 Jan 2023 08:29:05 +0100
To: testlist(a)lists.eden.one
Subject: [Testlist] Test (Listenmail)
From: Jan Eden via Testlist <testlist(a)lists.eden.one>
Reply-To: Jan Eden <mailuser(a)eden.one>
==============================
==============================
Authentication-Results: posteo.de; dmarc=pass (p=quarantine dis=none) header.from=janeden.net
Authentication-Results: posteo.de; spf=pass smtp.mailfrom=eden.one
Authentication-Results: posteo.de;
dkim=pass (2048-bit key) header.d=janeden.net header.i=(a)janeden.net header.b=VV5k+gN7;
dkim-atps=neutral
------------------------------
Delivered-To: gmailuser(a)gmail.com
ARC-Authentication-Results: i=1; mx.google.com;
dkim=pass header.i=(a)janeden.net header.s=s42 header.b=B8NPELsC;
spf=pass (google.com: domain of srs0=xtlx=5c=janeden.net=mailuser(a)eden.one designates 123.123.123.123 as permitted sender) smtp.mailfrom="SRS0=Xtlx=5C=janeden.net=mailuser(a)eden.one";
dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=janeden.net
Received-SPF: pass (google.com: domain of srs0=xtlx=5c=janeden.net=mailuser(a)eden.one designates 123.123.123.123 as permitted sender) client-ip=123.123.123.123;
Authentication-Results: mx.google.com;
dkim=pass header.i=(a)janeden.net header.s=s42 header.b=B8NPELsC;
spf=pass (google.com: domain of srs0=xtlx=5c=janeden.net=mailuser(a)eden.one designates 123.123.123.123 as permitted sender) smtp.mailfrom="SRS0=Xtlx=5C=janeden.net=mailuser(a)eden.one";
dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=janeden.net
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=janeden.net; s=s42; t=1672903599; h=from:from:reply-to:subject:subject:date:date:message-id:message-id:
to:to:cc:mime-version:mime-version:content-type:content-type; bh=wE7NXSkgnx9PGiavN4OZhJztvkqPDlemV3OGuEnLwNo=; b=B8NPELsC7r7WI62YOpEFUhESxumSjhP/aQNOlWRmusnTHgbHgjEHeCKNRhEDUeh+fRRVZw JnRVZx9WAU58/3UXx0XJIN6ivLYJnOtJ9vw3r1nVAzU6wk7RCE1Zx6zTJLybwHNijHcCn4 A2cRJZc1IUfJTAok3RHclBB8c10difp5SNPKVGRtNEPAOEFnG5vaNecPvQWc0+4EyHNCYX WSEARKApxpL31gBcojCEHjtdAFgmcknReosUN9I3PUiQQIxqFQ6uU9hA6XWyg6qCsEAll7 E1sGL9HopGIHQA2pHXPanQ9FZxOFou8BcjwN4w65Vygr78hAO5e2Ru6tDFwr4g==
Date: Thu, 5 Jan 2023 08:26:37 +0100
From: Jan Eden <mailuser(a)janeden.net>
To: gmailuser(a)googlemail.com
Subject: Test
==============================
2 years, 5 months

[MM3-users] Re: New releases
by Danil Smirnov
On Tue, 9 Jun 2020 at 00:05, Mark Sapiro <mark(a)msapiro.net> wrote:
> The first row of horizontal tabs is unchanged, but the `Settings` tab
> used to have a second horizontal row and now has a vertical list on the
> left.
>
Yeah Mark, thanks - now I see it :)
> After you upgraded did you run these django-admin commands?
> ```
> django-admin collectstatic --clear --noinput --verbosity 0
> django-admin compress
> django-admin compilemessages
> django-admin migrate
> ```
> These 4 commands should be run after every update to Postorius,
> HyperKitty or django_mainlman3.
>
Hm, interesting... Could you point me to some related docs please?
To upgrade, I've just bumped app versions in my Dockerfiles, built and
restarted...
Mailman-core worked right away with no issues.
Mailman-web (Hyperkitty) failed with the error:
----------
ERROR 2020-06-08 19:46:41,942 14 django.request Internal Server Error:
/hyperkitty/
Traceback (most recent call last):
File "/usr/lib/python3.6/site-packages/compressor/base.py", line 282, in
precompile
mod = import_module(mod_name)
File "/usr/lib/python3.6/importlib/__init__.py", line 126, in
import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "<frozen importlib._bootstrap>", line 994, in _gcd_import
File "<frozen importlib._bootstrap>", line 971, in _find_and_load
File "<frozen importlib._bootstrap>", line 953, in _find_and_load_unlocked
ModuleNotFoundError: No module named 'sassc -t compressed {infile}
{outfile}'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File
"/usr/lib/python3.6/site-packages/django/core/handlers/exception.py", line
34, in inner
response = get_response(request)
File "/usr/lib/python3.6/site-packages/django/core/handlers/base.py",
line 115, in _get_response
response = self.process_exception_by_middleware(e, request)
File "/usr/lib/python3.6/site-packages/django/core/handlers/base.py",
line 113, in _get_response
response = wrapped_callback(request, *callback_args, **callback_kwargs)
File "/usr/lib/python3.6/site-packages/hyperkitty/views/index.py", line
118, in index
return render(request, "hyperkitty/index.html", context)
File "/usr/lib/python3.6/site-packages/django/shortcuts.py", line 36, in
render
content = loader.render_to_string(template_name, context, request,
using=using)
File "/usr/lib/python3.6/site-packages/django/template/loader.py", line
62, in render_to_string
return template.render(context, request)
File
"/usr/lib/python3.6/site-packages/django/template/backends/django.py", line
61, in render
return self.template.render(context)
File "/usr/lib/python3.6/site-packages/django/template/base.py", line
171, in render
return self._render(context)
File "/usr/lib/python3.6/site-packages/django/template/base.py", line
163, in _render
return self.nodelist.render(context)
File "/usr/lib/python3.6/site-packages/django/template/base.py", line
937, in render
bit = node.render_annotated(context)
File "/usr/lib/python3.6/site-packages/django/template/base.py", line
904, in render_annotated
return self.render(context)
File "/usr/lib/python3.6/site-packages/django/template/loader_tags.py",
line 150, in render
return compiled_parent._render(context)
File "/usr/lib/python3.6/site-packages/django/template/base.py", line
163, in _render
return self.nodelist.render(context)
File "/usr/lib/python3.6/site-packages/django/template/base.py", line
937, in render
bit = node.render_annotated(context)
File "/usr/lib/python3.6/site-packages/django/template/base.py", line
904, in render_annotated
return self.render(context)
File
"/usr/lib/python3.6/site-packages/compressor/templatetags/compress.py",
line 143, in render
return self.render_compressed(context, self.kind, self.mode,
forced=forced)
File
"/usr/lib/python3.6/site-packages/compressor/templatetags/compress.py",
line 119, in render_compressed
rendered_output = compressor.output(mode, forced=forced,
basename=file_basename)
File "/usr/lib/python3.6/site-packages/compressor/css.py", line 46, in
output
ret.append(subnode.output(*args, **kwargs))
File "/usr/lib/python3.6/site-packages/compressor/css.py", line 48, in
output
return super(CssCompressor, self).output(*args, **kwargs)
File "/usr/lib/python3.6/site-packages/compressor/base.py", line 314, in
output
output = '\n'.join(self.filter_input(forced))
File "/usr/lib/python3.6/site-packages/compressor/base.py", line 254, in
filter_input
for hunk in self.hunks(forced):
File "/usr/lib/python3.6/site-packages/compressor/base.py", line 228, in
hunks
precompiled, value = self.precompile(value, **options)
File "/usr/lib/python3.6/site-packages/compressor/base.py", line 287, in
precompile
return True, filter.input(**kwargs)
File "/usr/lib/python3.6/site-packages/compressor/filters/base.py", line
239, in input
return super(CachedCompilerFilter, self).input(**kwargs)
File "/usr/lib/python3.6/site-packages/compressor/filters/base.py", line
206, in input
raise FilterError(err)
compressor.exceptions.FilterError: Error: It's not clear which file to
import for '@import "../libs/bootstrap/stylesheets/bootstrap"'.
Candidates:
../libs/bootstrap/stylesheets/_bootstrap.scss
../libs/bootstrap/stylesheets/bootstrap.scss
Please delete or rename all but one of these files.
on line 4 of
../mailman-web-data/static/hyperkitty/sass/hyperkitty.scss
>> @import "../libs/bootstrap/stylesheets/bootstrap";
----------
I've fixed the error by removing the older file which is
/opt/mailman-web-data/static/hyperkitty/libs/bootstrap/stylesheets/_bootstrap.scss
After that everything seems to be working fine.
My best regards,
Danil Smirnov
5 years

[MM3-users] Re: Postorius no connection to REST API
by Richard Rosner
Mark Sapiro wrote:
> On 8/12/21 12:01 AM, Richard Rosner wrote:
> > All the mailman processes should run as list and all mailman related
> things should be readable and writable by list.
I have set both /usr/bin/uwsgi-core and /usr/share/mailman3-web to be owned by lists, no changes yet. But at least mailman3-web now can actually be started without throwing an error.
> > Yes, I meant if you want those URLs to work, you have to pass them to
> uwsgi. You don't need all of them. mailman2 and postorius are
> synonyms as are archives and hyperkitty
> However, you could try using TCP to communicate with uwsgi rather than a
> Unix socket.
> This means replacing
> uwsgi-socket = /run/mailman3-web/uwsgi.sock
> with
> uwsgi-socket = 0.0.0.0:8000
> in your uwsgi.ini file and using directives like
> ProxyPass "/postorius" "http://127.0.0.1:8000/postorius"
> ProxyPass "/hyperkitty" "http://127.0.0.1:8000/hyperkitty"
> ProxyPass "/accounts" "http://127.0.0.1:8000/accounts"
> ProxyPass "/django" "http://127.0.0.1:8000/django"
> ProxyPass "/user-profile" "http://127.0.0.1:8000/user-profile"
> ProxyPass "/mailman3" "http://127.0.0.1:8000/mailman3"
> ProxyPass "/archives" "http://127.0.0.1:8000/archives"
>
>
> in apache.
I tried that switch and got ERR_HTTP2_PROTOCOL_ERROR.
From the apache log:
[Fri Aug 13 16:08:38.871462 2021] [mpm_event:notice] [pid 27808:tid 140008999584896] AH00489: Apache/2.4.48 (Debian) OpenSSL/1.1.1d mod_wsgi/4.6.5 \
Python/3.7 configured -- resuming normal operations
[Fri Aug 13 16:08:38.871603 2021] [core:notice] [pid 27808:tid 140008999584896] AH00094: Command line: '/usr/sbin/apache2'
[Fri Aug 13 16:08:42.881615 2021] [proxy_http:error] [pid 27809:tid 140008751261440] (20014)Internal error (specific information not available): [c\
lient 134.61.99.193:36563] AH01102: error reading status line from remote server 127.0.0.1:8000
[Fri Aug 13 16:08:44.072665 2021] [proxy_http:error] [pid 27809:tid 140008751261440] (20014)Internal error (specific information not available): [c\
lient 134.61.99.193:36563] AH01102: error reading status line from remote server 127.0.0.1:8000
[Fri Aug 13 16:08:49.277000 2021] [proxy_http:error] [pid 27810:tid 140008709297920] (20014)Internal error (specific information not available): [c\
lient 134.61.99.193:36696] AH01102: error reading status line from remote server 127.0.0.1:8000
I set them all to https. which solved the https error. But I still get Error 500.
From apache log:
[Fri Aug 13 15:47:58.833305 2021] [mpm_event:notice] [pid 26720:tid 139986206332032] AH00489: Apache/2.4.48 (Debian) OpenSSL/1.1.1d mod_wsgi/4.6.5 \
Python/3.7 configured -- resuming normal operations
[Fri Aug 13 15:47:58.833436 2021] [core:notice] [pid 26720:tid 139986206332032] AH00094: Command line: '/usr/sbin/apache2'
[Fri Aug 13 15:49:41.673108 2021] [ssl:error] [pid 26722:tid 139985899259648] [remote 127.0.0.1:8000] AH01961: SSL Proxy requested for lists.fsmuw.\
rwth-aachen.de:443 but not enabled [Hint: SSLProxyEngine]
[Fri Aug 13 15:49:41.905868 2021] [proxy:error] [pid 26722:tid 139985899259648] AH00961: https: failed to enable ssl support for 127.0.0.1:8000 (12\
7.0.0.1)
[Fri Aug 13 15:59:25.049708 2021] [ssl:error] [pid 26722:tid 139985899259648] [remote 127.0.0.1:8000] AH01961: SSL Proxy requested for lists.fsmuw.\
rwth-aachen.de:443 but not enabled [Hint: SSLProxyEngine]
[Fri Aug 13 15:59:25.059217 2021] [proxy:error] [pid 26722:tid 139985899259648] AH00961: https: failed to enable ssl support for 127.0.0.1:8000 (12\
7.0.0.1)
From the mailman-web log:
uwsgi socket 0 bound to TCP address 0.0.0.0:8000 fd 4
Python version: 3.7.3 (default, Jan 22 2021, 20:04:44) [GCC 8.3.0]
Python main interpreter initialized at 0x561db180adf0
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 3 seconds on interpreter 0x561db180adf0 pid: 26851 (default app)
*** uWSGI is running in multiple interpreter mode ***
spawned uWSGI master process (pid: 26851)
spawned uWSGI worker 1 (pid: 26861, cores: 2)
[uwsgi-daemons] spawning "python3 manage.py qcluster" (uid: 38 gid: 38)
13:48:04 [Q] INFO Q Cluster-26864 starting.
13:48:04 [Q] INFO Process-1:1 ready for work at 26866
13:48:04 [Q] INFO Process-1:2 ready for work at 26867
13:48:04 [Q] INFO Process-1:3 monitoring at 26868
13:48:04 [Q] INFO Process-1 guarding cluster at 26865
13:48:04 [Q] INFO Q Cluster-26864 running.
13:48:04 [Q] INFO Process-1:4 pushing tasks at 26869
So at least that seems to be fine now
> I am not familiar enough with apache/uwsgi configuration to be of more
> help. Have you seen https://wiki.list.org/x/12812344 and have you asked
> Debian for help with their package. They are the ones who should be
> supporting it https://www.debian.org/support.
I'll open an error report on mailman3-web. Maybe they have some input to that.
3 years, 9 months

[MM3-users] Re: Non-ascii characters missing from Pipermail archive txt and gz downloads
by Ruth Ivimey-Cook
Hi Mark
I'm not sure, but I think the problems are to do with the program you
are using to view the txt file.
A modern mail reader understands the Content-type: header and will
adjust its character processing accordingly, but a .txt file has no
default character encoding, so any text editor will have to "use its
best judgement". Some will default to utf-8, because that is compatible
with 7-bit ASCII (NOT Latin1) while others will just put characters out
and hope for the best (esentially leaving the result to the encoding of
the font).
In theory, a UTF-encoded text file can begin with the "BOM" marker, a
sequence of characters which is supposed to indicate which variety of
Unicode is in use, but this is rarely present, especially for UTF-8.
Try looking at your text file with a UTF-8 capable text editor **and
ensure that you tell the editor to use the UTF-8 encoding**. I expect it
will look ok then.
Hope this helps,
Ruth
On 09/04/2021 13:52, Mark Dale via Mailman-users wrote:
> 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.
>
> ===
> _______________________________________________
> 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/
--
Software Manager & Engineer
Tel: 01223 414180
Blog: http://www.ivimey.org/blog
LinkedIn: http://uk.linkedin.com/in/ruthivimeycook/
4 years, 2 months

[MM3-users] Re: templates
by Christian
It seems like something about my SPF or DKIM records are upsetting to gmail,
hence the bounces I'm guessing. That aside, this is what mail.log says:
May 5 08:02:50 zarathustra postfix/smtpd[14110]: AF07B1004A4:
client=localhost[127.0.0.1]
May 5 08:02:50 zarathustra postfix/cleanup[26614]: AF07B1004A4:
message-id=<046f01d97f5c$27c4ada0$774e08e0$(a)degrowthcalifornia.org>
May 5 08:02:50 zarathustra postfix/cleanup[26614]: AF07B1004A4: warning:
header Subject: [Degrowcali] test - please ignore from localhost[127.0.0.1];
from=<degrowcali-bounces+eappiah=dons.usfca.edu(a)lists.ccalternatives.org>
to=<eappiah(a)dons.usfca.edu> proto=ESMTP
helo=<zarathustra.ccalternatives.org>
May 5 08:02:50 zarathustra postfix/qmgr[2262]: AF07B1004A4:
from=<degrowcali-bounces+eappiah=dons.usfca.edu(a)lists.ccalternatives.org>,
size=6812, nrcpt=1 (queue active)
May 5 08:04:06 zarathustra postfix/smtp[25955]: AF07B1004A4:
to=<eappiah(a)dons.usfca.edu>,
relay=mxb-00277301.gslb.pphosted.com[148.163.158.109]:25, delay=76,
delays=0.01/0/61/15, dsn=2.0.0, status=sent (250 2.0.0 3qcf1p3wf4-1 Message
accepted for delivery)
May 5 08:04:06 zarathustra postfix/qmgr[2262]: AF07B1004A4: removed
May 5 08:05:01 zarathustra postfix/smtpd[14110]: C263A1004A4:
client=localhost[127.0.0.1]
May 5 08:05:01 zarathustra postfix/cleanup[27274]: C263A1004A4:
message-id=<046f01d97f5c$27c4ada0$774e08e0$(a)degrowthcalifornia.org>
May 5 08:05:01 zarathustra postfix/cleanup[27274]: C263A1004A4: warning:
header Subject: [Degrowcali] test - please ignore from localhost[127.0.0.1];
from=<degrowcali-bounces+adga=ucdavis.edu(a)lists.ccalternatives.org>
to=<adga(a)ucdavis.edu> proto=ESMTP helo=<zarathustra.ccalternatives.org>
May 5 08:05:01 zarathustra postfix/qmgr[2262]: C263A1004A4:
from=<degrowcali-bounces+adga=ucdavis.edu(a)lists.ccalternatives.org>,
size=6806, nrcpt=1 (queue active)
May 5 08:05:04 zarathustra postfix/smtp[25955]: C263A1004A4:
to=<adga(a)ucdavis.edu>,
relay=ucdavis-edu.mail.protection.outlook.com[104.47.66.10]:25, delay=2.5,
delays=0.01/0/0.15/2.3, dsn=2.6.0, status=sent (250 2.6.0
<046f01d97f5c$27c4ada0$774e08e0$(a)degrowthcalifornia.org>
[InternalId=117626269340390,
Hostname=BN8PR08MB6290.namprd08.prod.outlook.com] 16054 bytes in 0.131,
119.439 KB/sec Queued mail for delivery)
May 5 08:05:04 zarathustra postfix/qmgr[2262]: C263A1004A4: removed
May 5 08:07:12 zarathustra postfix/smtpd[14110]: D3CCE1004A4:
client=localhost[127.0.0.1]
May 5 08:07:12 zarathustra postfix/cleanup[27925]: D3CCE1004A4:
message-id=<046f01d97f5c$27c4ada0$774e08e0$(a)degrowthcalifornia.org>
May 5 08:07:12 zarathustra postfix/cleanup[27925]: D3CCE1004A4: warning:
header Subject: [Degrowcali] test - please ignore from localhost[127.0.0.1];
from=<degrowcali-bounces+chris.hebdon=yale.edu(a)lists.ccalternatives.org>
to=<chris.hebdon(a)yale.edu> proto=ESMTP helo=<zarathustra.ccalternatives.org>
May 5 08:07:12 zarathustra postfix/qmgr[2262]: D3CCE1004A4:
from=<degrowcali-bounces+chris.hebdon=yale.edu(a)lists.ccalternatives.org>,
size=6811, nrcpt=1 (queue active)
May 5 08:07:13 zarathustra postfix/smtp[27926]: D3CCE1004A4:
to=<chris.hebdon(a)yale.edu>,
relay=yale-edu.mail.protection.outlook.com[104.47.59.138]:25, delay=0.77,
delays=0.01/0.02/0.07/0.67, dsn=2.6.0, status=sent (250 2.6.0
<046f01d97f5c$27c4ada0$774e08e0$(a)degrowthcalifornia.org>
[InternalId=16887811415117,
Hostname=PH0PR08MB6757.namprd08.prod.outlook.com] 16093 bytes in 0.121,
129.491 KB/sec Queued mail for delivery)
May 5 08:07:13 zarathustra postfix/qmgr[2262]: D3CCE1004A4: removed
May 5 08:09:23 zarathustra postfix/cleanup[28574]: E394C1005BA:
message-id=<046f01d97f5c$27c4ada0$774e08e0$(a)degrowthcalifornia.org>
May 5 08:09:23 zarathustra postfix/cleanup[28574]: E394C1005BA: warning:
header Subject: [Degrowcali] test - please ignore from localhost[127.0.0.1];
from=<degrowcali-bounces+vortexanthony=hotmail.com(a)lists.ccalternatives.org>
to=<vortexanthony(a)hotmail.com> proto=ESMTP
helo=<zarathustra.ccalternatives.org>
May 5 08:09:23 zarathustra postfix/qmgr[2262]: E394C1005BA:
from=<degrowcali-bounces+vortexanthony=hotmail.com(a)lists.ccalternatives.org>
, size=6815, nrcpt=1 (queue active)
May 5 08:09:24 zarathustra postfix/smtp[28575]: E394C1005BA:
to=<vortexanthony(a)hotmail.com>,
relay=hotmail-com.olc.protection.outlook.com[104.47.17.161]:25, delay=0.58,
delays=0.01/0.02/0.41/0.14, dsn=5.7.1, status=bounced (host
hotmail-com.olc.protection.outlook.com[104.47.17.161] said: 550 5.7.1
Unfortunately, messages from [192.46.218.224] weren't sent. Please contact
your Internet service provider since part of their network is on our block
list (S3140). You can also refer your provider to
http://mail.live.com/mail/troubleshooting.aspx#errors.
[VI1EUR05FT042.eop-eur05.prod.protection.outlook.com
2023-05-05T15:09:24.433Z 08DB4D70FA71385D] (in reply to MAIL FROM command))
May 5 08:09:24 zarathustra postfix/smtp[28575]: E394C1005BA: lost
connection with hotmail-com.olc.protection.outlook.com[104.47.17.161] while
sending RCPT TO
May 5 08:09:24 zarathustra postfix/cleanup[28574]: 7C9B31005EB:
message-id=<20230505150924.7C9B31005EB(a)zarathustra.ccalternatives.org>
May 5 08:09:24 zarathustra postfix/qmgr[2262]: 7C9B31005EB: from=<>,
size=9884, nrcpt=1 (queue active)
May 5 08:09:24 zarathustra postfix/bounce[28579]: E394C1005BA: sender
non-delivery notification: 7C9B31005EB
May 5 08:09:24 zarathustra postfix/bounce[28579]: E394C1005BA: sender
non-delivery notification: 7C9B31005EB
May 5 08:09:24 zarathustra postfix/bounce[28579]: E394C1005BA: sender
non-delivery notification: 7C9B31005EB
May 5 08:09:24 zarathustra postfix/qmgr[2262]: E394C1005BA: removed
May 5 08:09:24 zarathustra postfix/lmtp[28581]: 7C9B31005EB:
to=<degrowcali-bounces+vortexanthony=hotmail.com(a)lists.ccalternatives.org>,
relay=127.0.0.1[127.0.0.1]:8024, delay=0.04, delays=0/0.01/0/0.02,
dsn=2.0.0, status=sent (250 Ok)
May 5 08:09:24 zarathustra postfix/qmgr[2262]: 7C9B31005EB: removed
May 5 08:11:35 zarathustra postfix/smtpd[14110]: 016931005BA:
client=localhost[127.0.0.1]
May 5 08:11:35 zarathustra postfix/cleanup[29218]: 016931005BA:
message-id=<046f01d97f5c$27c4ada0$774e08e0$(a)degrowthcalifornia.org>
May 5 08:11:35 zarathustra postfix/cleanup[29218]: 016931005BA: warning:
header Subject: [Degrowcali] test - please ignore from localhost[127.0.0.1];
from=<degrowcali-bounces+alaitz.aritza=gmail.com(a)lists.ccalternatives.org>
to=<alaitz.aritza(a)gmail.com> proto=ESMTP
helo=<zarathustra.ccalternatives.org>
May 5 08:11:35 zarathustra postfix/qmgr[2262]: 016931005BA:
from=<degrowcali-bounces+alaitz.aritza=gmail.com(a)lists.ccalternatives.org>,
size=6813, nrcpt=1 (queue active)
May 5 08:11:35 zarathustra postfix/smtp[29219]: 016931005BA:
to=<alaitz.aritza(a)gmail.com>,
relay=gmail-smtp-in.l.google.com[142.251.116.26]:25, delay=0.43,
delays=0.01/0.02/0.03/0.37, dsn=5.7.1, status=bounced (host
gmail-smtp-in.l.google.com[142.251.116.26] said: 550-5.7.1 [192.46.218.224
12] Our system has detected that this message is 550-5.7.1 likely
unsolicited mail. To reduce the amount of spam sent to Gmail, 550-5.7.1 this
message has been blocked. Please visit 550-5.7.1
https://support.google.com/mail/?p=UnsolicitedMessageError 550 5.7.1 for
more information. m12-20020a0568080f0c00b00389455db611si4492291oiw.127 -
gsmtp (in reply to end of DATA command))
May 5 08:11:35 zarathustra postfix/cleanup[29218]: 6ACFD1005EB:
message-id=<20230505151135.6ACFD1005EB(a)zarathustra.ccalternatives.org>
May 5 08:11:35 zarathustra postfix/qmgr[2262]: 6ACFD1005EB: from=<>,
size=9885, nrcpt=1 (queue active)
May 5 08:11:35 zarathustra postfix/bounce[29222]: 016931005BA: sender
non-delivery notification: 6ACFD1005EB
May 5 08:11:35 zarathustra postfix/qmgr[2262]: 016931005BA: removed
May 5 08:11:35 zarathustra postfix/lmtp[29224]: 6ACFD1005EB:
to=<degrowcali-bounces+alaitz.aritza=gmail.com(a)lists.ccalternatives.org>,
relay=127.0.0.1[127.0.0.1]:8024, delay=0.03, delays=0/0.01/0/0.01,
dsn=2.0.0, status=sent (250 Ok)
May 5 08:11:35 zarathustra postfix/qmgr[2262]: 6ACFD1005EB: removed
May 5 08:13:46 zarathustra postfix/smtpd[14110]: 1522D1004A4:
client=localhost[127.0.0.1]
May 5 08:13:46 zarathustra postfix/cleanup[29884]: 1522D1004A4:
message-id=<046f01d97f5c$27c4ada0$774e08e0$(a)degrowthcalifornia.org>
May 5 08:13:46 zarathustra postfix/cleanup[29884]: 1522D1004A4: warning:
header Subject: [Degrowcali] test - please ignore from localhost[127.0.0.1];
from=<degrowcali-bounces+kamccammon=ucdavis.edu(a)lists.ccalternatives.org>
to=<kamccammon(a)ucdavis.edu> proto=ESMTP
helo=<zarathustra.ccalternatives.org>
May 5 08:13:46 zarathustra postfix/qmgr[2262]: 1522D1004A4:
from=<degrowcali-bounces+kamccammon=ucdavis.edu(a)lists.ccalternatives.org>,
size=6812, nrcpt=1 (queue active)
May 5 08:13:46 zarathustra postfix/smtpd[14110]: disconnect from
localhost[127.0.0.1] ehlo=1 mail=25 rcpt=25 data=25 quit=1 commands=77
May 5 08:13:46 zarathustra postfix/smtpd[14110]: connect from
localhost[127.0.0.1]
May 5 08:13:46 zarathustra postfix/smtpd[14110]: 1D3FB1005DA:
client=localhost[127.0.0.1]
May 5 08:13:46 zarathustra postfix/cleanup[29884]: 1D3FB1005DA: warning:
header Subject: Degrowcali mailing list probe message from
localhost[127.0.0.1];
from=<degrowcali-bounces+6397d6fde210be0b39dbf22a9868e61d6e2d0f23(a)lists.ccal
ternatives.org> to=<juliankrauspolk(a)gmail.com> proto=ESMTP
helo=<zarathustra.ccalternatives.org>
May 5 08:13:46 zarathustra postfix/cleanup[29884]: 1D3FB1005DA:
message-id=<168329874052.765.12737190159456781981(a)zarathustra.ccalternatives
.org>
May 5 08:13:46 zarathustra postfix/cleanup[29884]: 1D3FB1005DA: warning:
header Subject: Undelivered Mail Returned to Sender from
localhost[127.0.0.1];
from=<degrowcali-bounces+6397d6fde210be0b39dbf22a9868e61d6e2d0f23(a)lists.ccal
ternatives.org> to=<juliankrauspolk(a)gmail.com> proto=ESMTP
helo=<zarathustra.ccalternatives.org>
May 5 08:13:46 zarathustra postfix/cleanup[29884]: 1D3FB1005DA: warning:
header Subject: [Degrowcali] test - please ignore from localhost[127.0.0.1];
from=<degrowcali-bounces+6397d6fde210be0b39dbf22a9868e61d6e2d0f23(a)lists.ccal
ternatives.org> to=<juliankrauspolk(a)gmail.com> proto=ESMTP
helo=<zarathustra.ccalternatives.org>
May 5 08:13:46 zarathustra postfix/qmgr[2262]: 1D3FB1005DA:
from=<degrowcali-bounces+6397d6fde210be0b39dbf22a9868e61d6e2d0f23(a)lists.ccal
ternatives.org>, size=11949, nrcpt=1 (queue active)
May 5 08:13:46 zarathustra postfix/smtpd[14110]: disconnect from
localhost[127.0.0.1] ehlo=1 mail=1 rcpt=1 data=1 quit=1 commands=5
May 5 08:13:46 zarathustra postfix/smtpd[14110]: connect from
localhost[127.0.0.1]
May 5 08:13:46 zarathustra postfix/smtpd[14110]: 2707E1005EB:
client=localhost[127.0.0.1]
May 5 08:13:46 zarathustra postfix/cleanup[29884]: 2707E1005EB: warning:
header Subject: Degrowcali mailing list probe message from
localhost[127.0.0.1];
from=<degrowcali-bounces+62749dfe16f9d39e2cd0c3e94754723efbe8169d(a)lists.ccal
ternatives.org> to=<baronchadg(a)gmail.com> proto=ESMTP
helo=<zarathustra.ccalternatives.org>
May 5 08:13:46 zarathustra postfix/cleanup[29884]: 2707E1005EB:
message-id=<168329886073.765.17844938860507947692(a)zarathustra.ccalternatives
.org>
-----Original Message-----
From: Mark Sapiro <mark(a)msapiro.net>
Sent: Friday, May 5, 2023 5:43 PM
To: mailman-users(a)mailman3.org
Subject: [MM3-users] Re: templates
On 5/5/23 17:04, Christian via Mailman-users wrote:
>>From bounce.log
>
> May 05 07:59:00 2023 (765) Member juliankrauspolk(a)gmail.com
<mailto:juliankrauspolk@gmail.com> on list
> degrowcali.lists.ccalternatives.org, bounce score = 5.
> May 05 07:59:00 2023 (765) Member juliankrauspolk(a)gmail.com
<mailto:juliankrauspolk@gmail.com> on list
> degrowcali.lists.ccalternatives.org, bounce score 5 >= threshold 5,
> sending probe.
> May 05 08:01:00 2023 (765) Member baronchadg(a)gmail.com
<mailto:baronchadg@gmail.com> on list
> degrowcali.lists.ccalternatives.org, bounce score = 5.
> May 05 08:01:00 2023 (765) Member baronchadg(a)gmail.com
<mailto:baronchadg@gmail.com> on list
> degrowcali.lists.ccalternatives.org, bounce score 5 >= threshold 5,
> sending probe.
> May 05 08:11:01 2023 (765) Member vortexanthony(a)hotmail.com
<mailto:vortexanthony@hotmail.com> on list
> degrowcali.lists.ccalternatives.org, bounce score = 1.
> May 05 08:13:01 2023 (765) Member alaitz.aritza(a)gmail.com
<mailto:alaitz.aritza@gmail.com> on list
> degrowcali.lists.ccalternatives.org, bounce score = 5.
> May 05 08:13:01 2023 (765) Member alaitz.aritza(a)gmail.com
<mailto:alaitz.aritza@gmail.com> on list
> degrowcali.lists.ccalternatives.org, bounce score 5 >= threshold 5,
> sending probe.
> May 05 08:15:01 2023 (765) Probe bounce received for member
> juliankrauspolk(a)gmail.com <mailto:juliankrauspolk@gmail.com> on list
degrowcali.lists.ccalternatives.org.
> May 05 08:15:01 2023 (765) Disabling delivery for
> juliankrauspolk(a)gmail.com <mailto:juliankrauspolk@gmail.com> on list
degrowcali.lists.ccalternatives.org
> by bounce May 05 08:15:02 2023 (765) Probe bounce received for member
> alaitz.aritza(a)gmail.com <mailto:alaitz.aritza@gmail.com> on list
degrowcali.lists.ccalternatives.org.
> May 05 08:15:02 2023 (765) Disabling delivery for
> alaitz.aritza(a)gmail.com <mailto:alaitz.aritza@gmail.com> on list
degrowcali.lists.ccalternatives.org by
> bounce May 05 08:15:02 2023 (765) Probe bounce received for member
> baronchadg(a)gmail.com <mailto:baronchadg@gmail.com> on list
degrowcali.lists.ccalternatives.org.
> May 05 08:15:02 2023 (765) Disabling delivery for baronchadg(a)gmail.com
<mailto:baronchadg@gmail.com>
> on list degrowcali.lists.ccalternatives.org by bounce May 05 08:17:02
> 2023 (765) Residual bounce received for member
> juliankrauspolk(a)gmail.com <mailto:juliankrauspolk@gmail.com> on list
degrowcali.lists.ccalternatives.org.
> May 05 08:17:02 2023 (765) Residual bounce received for member
> alaitz.aritza(a)gmail.com <mailto:alaitz.aritza@gmail.com> on list
degrowcali.lists.ccalternatives.org.
> May 05 08:17:02 2023 (765) Residual bounce received for member
> baronchadg(a)gmail.com <mailto:baronchadg@gmail.com> on list
degrowcali.lists.ccalternatives.org.
So some of your user's, but not 24, are bouncing. If your list's bounce
processing settings have Notify owner on disable = Yes, the owner should
receive a notice including the DSN. If Notify owner on bounce increment =
Yes, the owner will also get notices when a user's score is incremented as
for vortexanthony(a)hotmail.com <mailto:vortexanthony@hotmail.com> above.
This still doesn't answer the other users. Have you looked at the MTA logs?
--
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/
Archived at:
https://lists.mailman3.org/archives/list/mailman-users@mailman3.org/message/
IFXPEUII4TCT5OIH7V3YKPTAIWSEQIGA/
This message sent to csa(a)web-analysts.net <mailto:csa@web-analysts.net>
2 years, 1 month

[MM3-users] Re: Confirmation emails to Users has wrong domain name (example.com!)
by Odhiambo Washington
On Thu, Sep 30, 2021 at 4:09 PM Abhilash Raj <maxking(a)asynchronous.in>
wrote:
>
>
> 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.
>
Thank you very much.
--
Best regards,
Odhiambo WASHINGTON,
Nairobi,KE
+254 7 3200 0004/+254 7 2274 3223
"Oh, the cruft.", egrep -v '^$|^.*#' :-)
3 years, 8 months

[MM3-users] Re: lmtp runner not starting
by Guillermo Hernandez (Oldno7)
El 1/4/23 a las 21:00, Guillermo Hernandez (Oldno7) via Mailman-users
escribió:
>
> El 1/4/23 a las 20:44, Mark Sapiro escribió:
>> ...
>> lmtp runner did not start because at some point it had died and
>> restarting Mailman won't restart a runner that died and was marked to
>> not restart.
>>
>> You need to stop Mailman and make sure when mailman is stopped that
>> there are no files in mailman's var/locks/ directory (remove any that
>> are there) and then start Mailman and lmtp runner should start.
>>
> I stopped mailman and removed all that was in there (there were many
> locked registers). Restarted mailman, and it shows the same error that
> in my previous mail.
>
> Now there is two new locked files, one (master.lck) which its content
> is the name of the other file. And the second one has the same content:
>
> master.lck|www.proteccion-civil.eu|9389|7022761192045613065
>
> will try deleting the content of var/locks and restarting the server
same results lmtp runner is diying. Now I know thata part of the lock
file is the pid of the master runner.
Apr 01 21:03:03 2023 (11548) Master started
Apr 01 21:03:11 2023 (11563) virgin runner started.
Apr 01 21:03:13 2023 (11553) bounces runner started.
Apr 01 21:03:14 2023 (11561) retry runner started.
Apr 01 21:03:15 2023 (11560) rest runner started.
[2023-04-01 21:03:15 +0200] [11560] [INFO] Starting gunicorn 20.1.0
[2023-04-01 21:03:15 +0200] [11560] [INFO] Listening at:
http://10.0.1.42:8001 (11560)
[2023-04-01 21:03:15 +0200] [11560] [INFO] Using worker: sync
[2023-04-01 21:03:15 +0200] [11567] [INFO] Booting worker with pid: 11567
[2023-04-01 21:03:15 +0200] [11568] [INFO] Booting worker with pid: 11568
Apr 01 21:03:16 2023 (11564) digest runner started.
Apr 01 21:03:17 2023 (11562) task runner started.
Apr 01 21:03:17 2023 (11562) Task runner evicted 0 expired pendings
Apr 01 21:03:17 2023 (11562) Task runner deleted 0 orphaned workflows
Apr 01 21:03:17 2023 (11562) Task runner deleted 0 orphaned requests
Apr 01 21:03:17 2023 (11562) Task runner deleted 0 orphaned messages
Apr 01 21:03:17 2023 (11562) Task runner evicted expired cache entries
Apr 01 21:03:18 2023 (11559) pipeline runner started.
Apr 01 21:03:19 2023 (11555) in runner started.
Apr 01 21:03:19 2023 (11554) command runner started.
Apr 01 21:03:20 2023 (11558) out runner started.
Apr 01 21:03:22 2023 (11557) nntp runner started.
Apr 01 21:03:23 2023 (11552) archive runner started.
a ps ax output:
11548 - IsJ 0:01.92 /usr/local/bin/python3.9 /usr/local/bin/master
--force -C /usr/local/mailman3/var/etc/mailman.cfg
11552 - SJ 0:01.97 /usr/local/bin/python3.9 /usr/local/bin/runner -C
/usr/local/mailman3/var/etc/mailman.cfg --runner=archive:0:1
11553 - IJ 0:02.10 /usr/local/bin/python3.9 /usr/local/bin/runner -C
/usr/local/mailman3/var/etc/mailman.cfg --runner=bounces:0:1
11554 - SJ 0:01.94 /usr/local/bin/python3.9 /usr/local/bin/runner -C
/usr/local/mailman3/var/etc/mailman.cfg --runner=command:0:1
11555 - SJ 0:01.94 /usr/local/bin/python3.9 /usr/local/bin/runner -C
/usr/local/mailman3/var/etc/mailman.cfg --runner=in:0:1
11556 - ZJ 0:02.21 <defunct>
11557 - SJ 0:01.95 /usr/local/bin/python3.9 /usr/local/bin/runner -C
/usr/local/mailman3/var/etc/mailman.cfg --runner=nntp:0:1
11558 - SJ 0:01.93 /usr/local/bin/python3.9 /usr/local/bin/runner -C
/usr/local/mailman3/var/etc/mailman.cfg --runner=out:0:1
11559 - SJ 0:01.94 /usr/local/bin/python3.9 /usr/local/bin/runner -C
/usr/local/mailman3/var/etc/mailman.cfg --runner=pipeline:0:1
11560 - SJ 0:02.02 /usr/local/bin/python3.9 /usr/local/bin/runner -C
/usr/local/mailman3/var/etc/mailman.cfg --runner=rest:0:1
11561 - IJ 0:01.94 /usr/local/bin/python3.9 /usr/local/bin/runner -C
/usr/local/mailman3/var/etc/mailman.cfg --runner=retry:0:1
11562 - IJ 0:02.02 /usr/local/bin/python3.9 /usr/local/bin/runner -C
/usr/local/mailman3/var/etc/mailman.cfg --runner=task:0:1
11563 - SJ 0:01.95 /usr/local/bin/python3.9 /usr/local/bin/runner -C
/usr/local/mailman3/var/etc/mailman.cfg --runner=virgin:0:1
11564 - SJ 0:01.93 /usr/local/bin/python3.9 /usr/local/bin/runner -C
/usr/local/mailman3/var/etc/mailman.cfg --runner=digest:0:1
11567 - IJ 0:00.01 /usr/local/bin/python3.9 /usr/local/bin/runner -C
/usr/local/mailman3/var/etc/mailman.cfg --runner=rest:0:1
11568 - IJ 0:00.01 /usr/local/bin/python3.9 /usr/local/bin/runner -C
/usr/local/mailman3/var/etc/mailman.cfg --runner=rest:0:1
>
>
>
>
>
>> As to why it died in the first place, there should be something in
>> mailman.log from the time it died.
>>
--
___________________________________________
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: Prototype import [was: Re: Setup Question: Disk-Layout (Migrating from Mailman 2.1)]
by Mihai Moldovan
* On 4/18/25 04:23, Mark Sapiro wrote:
> On 4/17/25 11:35 AM, Mihai Moldovan wrote:
>>
>> New incoming messages will have the correct data, of course, but
>> imported ones wouldn't, so I'll have to use a more sophisticated
>> approach to handle them, probably by going through mailman's email
>> wrapper, figuring out how to generate a msgdata object for a message,
>> using RFC2369.process and maybe more.
>
> Here's an example script. You need to run this with
> /opt/mailman/mm/venv/bin/python to get access to the mailman imports.
> ```
> from mailbox import Maildir, mbox
> from mailman.email.message import Message
> from mailman.handlers.rfc2369 import process
> from mailman.interfaces.listmanager import IListManager
> from mailman.utilities.email import add_message_hash
> from zope.component import getUtility
> mb = mbox('path/to/mbox', factory=Message, create=False)
> md = Maildir('path/to/maildir', create=False)
> mlist = getUtility(IListManager).get_by_list_id('your.list.id')
> for msg in mb:
> add_message_hash(msg)
> process(mlist, msg, {})
> md.add(msg)
> mb.close()
> md.close()
> ```
Thank you.
Unfortunately, I'm having a hard time getting this to work correctly. My current
approach is (which is modified from yours, for instance to use
Prototype.archive_message() instead of writing directly to a Maildir):
```py
import copy
import sys
from mailbox import mbox
from mailman.archiving.prototype import Prototype
from mailman.core import initialize
from mailman.email.message import Message
from mailman.handlers.rfc_2369 import process
from mailman.interfaces.listmanager import IListManager
from mailman.interfaces.mailinglist import IMailingList
from mailman.utilities.email import add_message_hash
from zope.component import getUtility
initialize.initialize()
if (len(sys.argv) < 3):
print('Usage: {0} <list-id> <mbox-file>'.format(sys.argv[0]), file=sys.stderr)
exit(1)
mb = mbox(sys.argv[2], factory=Message, create=False)
mlist = getUtility(IListManager).get_by_list_id(sys.argv[1])
for msg in mb:
try:
add_message_hash(msg)
process(mlist, msg {})
Prototype.archive_message(mlist, msg)
except Exception as e:
print("Error when adding {0}: {1}".format(msg['message-id'], str(e)),
file=sys.stderr)
mb.close()
```
This returns "Error when adding None: '_PartialFile' object has no attribute
'header_max_count'" for each message.
This, including getting None for the Message-ID, stumped me and I got on to
debugging this.
Indeed, even something as simple as
```py
for msg in mb:
print(type(msg))
print(msg['message-id'])
print(msg)
exit(0)
```
results in getting a None for the Message-ID and a stack trace:
<class 'mailman.email.message.Message'>
None
Traceback (most recent call last):
File "/root/mailman3/prototype-import.py", line 29, in <module>
print(msg)
File "/usr/lib/python3.12/email/message.py", line 165, in __str__
return self.as_string()
^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/mailman/email/message.py", line 55, in
as_string
value = email.message.Message.as_string(self)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3.12/email/message.py", line 188, in as_string
g.flatten(self, unixfrom=unixfrom)
File "/usr/lib/python3.12/email/generator.py", line 98, in flatten
policy = policy.clone(max_line_length=self.maxheaderlen)
^^^^^^^^^^^^
AttributeError: '_PartialFile' object has no attribute 'clone'. Did you mean:
'close'?
This eventually led me to realize that passing mailman.email.message.Message as
the factory to mbox() internally calls factory(msg), and the base class of
Message (email.message.Message) has an __init__ function that takes the policy
parameter, so it looks as if it's registering the mailbox message incorrectly as
the policy handler, which is totally wrong of course.
If I change the call to mb = mbox(sys.argv[2], factory=None, create=False), the
output looks more promising, so converting the data to
mailman.email.message.Message first seems to have been the wrong idea on my part:
```
<class 'mailbox.mboxMessage'>
<mailman.1.1399151409.10314.x2go-i18n(a)lists.x2go.org>
Return-Path: <mailman-bounces(a)lists.x2go.org>
[...]
```
and indeed, if I let the import actually happen, it works.
The imported messages, do have a Message-ID-Hash, but the Archived-At and
List-Archive headers are empty (literally <>).
Do you have an example message that was archived through Prototype? What are the
proper header values for this module? I believe that Archived-At should be the
Message-ID-Hash and the List-Archive header contain... well, given that the
Prototype archiver is not meant to be publicly available, probably a file:// URL?
Mihai
1 month, 2 weeks

[MM3-users] Re: error changed after restart (was: KeyError: 'get_requests_count' after an upgrade)
by Abhilash Raj
On Sat, Feb 6, 2021, at 3:04 AM, Guillermo Hernandez (Oldno7) via Mailman-users wrote:
> I restarted de server and the error changed. Now the log shows
> "KeyError: 'subscription_mode'":
Did you also restart Mailman Core after the upgrade?
>
> 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/
> >
> _______________________________________________
> 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: Held messages: Long time waiating for response of the Mailman API
by Stephan Krinetzki
Mark Sapiro wrote:
> On 1/29/22 05:48, Jacob Sievert via Mailman-users wrote:
> > Hello,
> > we seem to have the same problem right now.
> > We are still on python3.6 and postgresql 12.9
> > I looked at our Table pendedkeyvalue and we have roughly 35k rows in
> > that table,
> > is that normal or shouldn't those get cleaned up after a while?
> > Yes they should. This is https://gitlab.com/mailman/mailman/-/issues/257
> fixed in Mailman core 3.3.5. Also in Mailman 3.3.5 is a new Task runner
> that runs periodic tasks, one of which is to remove orphaned pendings.
> This may also be the issue for the OP in this thread if that
> pendedkeyvalue table is also large.
I can confirm this. We have a total of ~580000 Rows in the pendedkeyvalue table. Since last wednsday even the hourly job quits (Out of memory exception)
> Here is a mailman shell script that will clean that up.
> # Prior to Mailman 3.3.5, some tokens for user confirmations were pended
> with
> # too long a lifetime. This script removes those pendings based on when
> they
> # were pended and the configured pending_request_life rather than their
> # expiration.
>
> # Also prior to Mailman 3.3.5, pended held_message tokens for email handling
> # of the message were not removed when the message was handled via REST.
> This
> # script removes those pendings too.
>
> # This is run with
> # mailman shell -r delete_orphans_expireds
> # after saving it as
> # /opt/mailman/mm/venv/bin/delete_orphans_expireds.py
>
> from datetime import datetime
> from lazr.config import as_timedelta
> from mailman.config import config
> from mailman.database.transaction import transactional
> from mailman.interfaces.pending import IPendings
> from zope.component import getUtility
>
> pendings = getUtility(IPendings)
>
> def is_request(id):
> if config.db.store.execute(
> 'SELECT * FROM _request WHERE id = {};'.format(id)).rowcount > 0:
> return True
> return False
>
> then = datetime.now() - as_timedelta(config.mailman.pending_request_life)
> thenm = datetime.now() - as_timedelta(config.mailman.moderator_request_life)
>
> def fromisoformat(x):
> if hasattr(datetime, 'fromisoformat'):
> return datetime.fromisoformat(x)
> try:
> return datetime.strptime(x, '%Y-%m-%dT%H:%M:%S.%f')
> except ValueError:
> return datetime.strptime(x, '%Y-%m-%dT%H:%M:%S')
>
> @transactional
> def delete_orphans_expireds():
> count = 0
> for token, data in pendings.find(pend_type='held message'):
> if data and not is_request(data['id']):
> result = pendings.confirm(token, expunge=True)
> count += 1
> print(f'expunged {count} orphaned pended held messages')
>
> count = 0
> for token, data in pendings.find(pend_type='data'):
> if data and data['_mod_hold_date']:
> when = data['_mod_hold_date']
> if isinstance(when, str):
> when = fromisoformat(when)
> if when < thenm:
> result = pendings.confirm(token, expunge=True)
> count += 1
> print(f'expunged {count} expired held messages')
>
> pends = list(pendings.find(pend_type='subscription'))
> pends += list(pendings.find(pend_type='unsubscription'))
> count = 0
> for token, values in pends:
> if values and values['token_owner'] == 'subscriber':
> when = values['when']
> if isinstance(when, str):
> when = fromisoformat(when)
> if when < then:
> result = pendings.confirm(token, expunge=True)
> count += 1
> print(f'expunged {count} expired (un)subscription confirmations')
>
> The above says to save the script at
> /opt/mailman/mm/venv/bin/delete_orphans_expireds.py but that path may
> need to be adjusted based in where Mailman's bin/ directory is in your
> installation.
Thanks for the Script Mark! WIth the Script, the result is:
mailman shell -r delete_orphans_expireds
Jan 31 09:15:46 2022 (7980) Database url: postgres://mailman:XXXXXXXX@127.0.0.1/YYYYYYY
expunged 95918 orphaned pended held messages
expunged 7958 expired held messages
expunged 22372 expired (un)subscription confirmations
And the pendedkeyvalue table has significant lower entries (~ 92000) and now the process to accept or decline a held message ist a lot of faster. Maybe we will take the database to a seperate server to get more speed - but for the moment it is fast enough.
Thanks again and thanks to Jacob Sievert for the pointer to the size of the pendedkeyvalue table.
3 years, 4 months

[MM3-users] Re: integrating mm3 with postfix / lmtp
by Abhilash Raj
On Nov 13 2017, at 1:34 am, Thor Atle Rustad <thor.rustad(a)gmail.com> wrote:
> 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").
Containers usually run with uid namespace, so it doesn't really matter what uid is used outside of container.
Unless, you mount /etc/shadow from host in to the container, which isn't really needed for the images.
>
> 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 (mailto:maxking@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 (mailto:mark@msapiro.net)> wrote:
> > >
> > > > On October 26, 2017 7:30:35 PM PDT, "Fabian A. Santiago" <fsantiago(a)garbage-juice.com (mailto:fsantiago@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 (mailto:mark@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 (mailto:maxking@asynchronous.in)
> > _______________________________________________
> > Mailman-users mailing list
> > mailman-users(a)mailman3.org (mailto:mailman-users@mailman3.org)
> > https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/
>
7 years, 6 months

[MM3-users] Re: mail loops back to myself
by Florian Sukup
On 6/9/25 05:05, Mark Sapiro wrote:
> On 6/8/25 16:04, Florian Sukup wrote:
>>
>> I set up mailman, created a site/domain (lists.yyy.com) My hostname
>> is host.xxx.com . My IP has a RDNS entry: reverse.rrr.com .
>
> Why is the RDNS to reverse.rrr.com and not host.xxx.com. It is important
> for mail delivery to have full circle DNS. I.e. the sending server
> should have an A record for its IP and revers DNS for that IP should
> point back to the sending server's name. I'm guessing that rrr.com is a
> hosting provider and you don't control the rDNS for that IP, but you
> should try to get them to change it for you. Without that change,
> delivery of your outbound mail, at least to large ISPs, will be
> problematic at best.
>
The setup has historic reasons. However I can eliminate reverse.rrr.com
completely and replace it by host.xxx.com. Right now reverse.rrr.com has
an A-record pointing to the host's ip address.
>
>> When I send an email to my mailing list mylist(a)lists.yyy.com I receive
>> an error email. The logfile says the following:
>>
>> ...
>> Jun 9 00:23:38 arvak postfix/relay/smtp[]: 094895FADB:
>> to=<mylist(a)lists.yyy.com>, relay=reverse.rrr.com[m.y.i.p]:25,
>> delay=0.06, delays=0.03/0.01/0.02/0, dsn=5.4.6, status=bounced (mail
>> for lists.yyy.com loops back to myself)
>
> What is the output from `postconf -n`?
>
alias_database = hash:/etc/aliases
alias_maps = hash:/etc/aliases
append_dot_mydomain = no
biff = no
compatibility_level = 2
inet_interfaces = all
inet_protocols = all
local_recipient_maps = proxy:unix:passwd.byname $alias_maps
hash:/var/lib/mailman3/data/postfix_lmtp
mailbox_size_limit = 0
message_size_limit = 0
mydestination = localhost, localhost.localdomain, arvak
myhostname = host.xxx.com
mynetworks = 127.0.0.0/8 [::ffff:127.0.0.0]/104 [::1]/128, 192.168.77.0/24
myorigin = /etc/mailname
owner_request_special = no
readme_directory = no
recipient_delimiter = +
relay_domains = ${{$compatibility_level} < {2} ? {$mydestination} : {}}
hash:/var/lib/mailman3/data/postfix_domains
relayhost =
smtp_tls_CApath = /etc/ssl/certs
smtp_tls_cert_file = /etc/letsencrypt/live/host.xxx.com/fullchain.pem
smtp_tls_key_file = /etc/letsencrypt/live/host.xxx.com/privkey.pem
smtp_tls_loglevel = 3
smtp_tls_security_level = may
smtp_tls_session_cache_database = btree:${data_directory}/smtp_scache
smtp_use_tls = yes
smtpd_banner = $myhostname ESMTP $mail_name (Debian/GNU)
smtpd_relay_restrictions = permit_mynetworks permit_sasl_authenticated
defer_unauth_destination
smtpd_tls_cert_file = /etc/letsencrypt/live/host.xxx.com/fullchain.pem
smtpd_tls_key_file = /etc/letsencrypt/live/host.xxx.com/privkey.pem
smtpd_tls_loglevel = 3
smtpd_tls_security_level = may
smtpd_use_tls = yes
transport_maps = hash:/var/lib/mailman3/data/postfix_lmtp
virtual_alias_domains = 9 different domains, however not host.xxx.com,
lists.yyy.com or reverse.rrr.com
virtual_alias_maps = hash:/etc/postfix/virtual
>> Jun 9 00:23:38 arvak postfix/smtpd[114119]: disconnect from
>> host.xxx.com[m.y.i.p] ehlo=1 quit=1 commands=2
>> ...
>>
>> The MX record of lists.yyy.com points to reverse.rrr.com. Not sure if
>> this is the best idea?
>
> reverse.rrr.com has no A or AAAA record. An MX MUST point to a domain
> that has an A or AAAA record. The MX should point to host.xxx.com.
>
Will be resolved (s. above).
>> Can anyone give me a hint where to search for this error?
>
> The output from `postconf -n` would help. Also, have you set up postfix
> per
> https://docs.mailman3.org/projects/mailman/en/latest/src/mailman/docs/mta.h… ?
>
Basically yes, but I see a few differences which all worked on my test
installation. Here comes my mailman.cfg:
[mailman]
site_owner: mailman@...
noreply_address: noreply
default_language: en
sender_headers: from from_ reply-to sender
email_commands_max_lines: 10
pending_request_life: 3d
cache_life: 7d
pre_hook:
post_hook:
layout: debian
filtered_messages_are_preservable: no
html_to_plain_text_command: /usr/bin/lynx -dump $filename
listname_chars: [-_.0-9a-z]
[shell]
prompt: >>>
banner: Welcome to the GNU Mailman shell
use_ipython: no
history_file:
[paths.debian]
var_dir: /var/lib/mailman3
queue_dir: $var_dir/queue
bin_dir: /usr/lib/mailman3/bin
list_data_dir: $var_dir/lists
log_dir: /var/log/mailman3
lock_dir: $var_dir/locks
data_dir: $var_dir/data
cache_dir: $var_dir/cache
etc_dir: /etc/mailman3
ext_dir: $var_dir/ext
messages_dir: $var_dir/messages
archive_dir: $var_dir/archives
template_dir: $var_dir/templates
pid_file: /run/mailman3/master.pid
lock_file: $lock_dir/master.lck
[database]
class: mailman.database.sqlite.SQLiteDatabase
url: sqlite:///$DATA_DIR/mailman.db
debug: no
[logging.debian]
format: %(asctime)s (%(process)d) %(message)s
datefmt: %b %d %H:%M:%S %Y
propagate: no
level: info
path: mailman.log
[webservice]
hostname: localhost
port: 8001
use_https: no
show_tracebacks: yes
api_version: 3.1
admin_user: ...
admin_pass: ...
[mta]
incoming: mailman.mta.postfix.LMTP
outgoing: mailman.mta.deliver.deliver
smtp_host: localhost
smtp_port: 25
smtp_user:
smtp_pass:
lmtp_host: 127.0.0.1
lmtp_port: 8024
configuration: python:mailman.config.postfix
Thanks for your help,
Florian.
6 hours, 56 minutes

[MM3-users] Re: Member Issue Discovered
by Brian Carpenter
On 10/20/20 11:19 PM, Mark Sapiro wrote:
> On 10/20/20 6:54 AM, Brian Carpenter wrote:
>> 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.
>
> I'd like to understand the real requirement. It seems to me that this
> issue has come up because a list admin wanted to change the display name
> shown in the membership roster for a user. Since there is currently no
> UI to do this, the list admin tried to do it by unsubscribing and
> resubscribing the user. That didn't work which led to this
> "unsubscribing a user should remove the user's information" thread, but
> the real issue is the lack of a UI for changing display names. It seems
> if that UI existed and was available, the "unsubscribing a user should
> remove the user's information" issue would never have been raised.
There are two real requirements. One is to be able to do something as
easy as changing a name for a list member. I did a lot of testing with
the relationship between a name used for a subscription versus a name
used for registering via the U.I. (Postorius/Django) and it is very
confusing. I still am having a very difficult time understanding the
logic presented here for the way Mailman 3 handles user information.
The second requirement is ALL data should be removed if someone
unsubscribes from a list that is just a list member of a single list. I
feel very strongly about that. I don't really care for the reasoning
behind why the data is retained. I just think it should be removed for a
list member who has no need for an account that manages multiple email
address and is subscribed to multiple lists.
I host many single lists. So it is very important to me, and as an
advocate for my clients, I will state very clearly how important it is
to me (and my clients) regards of other user scenarios out there
(looking at you Mr. Turnbull). I care about my own.
> So perhaps what we should be talking about is UIs for changing user
> information, what they would look like and who should be able to change
> what.
That is a start and I thought I brought that up. We also need a separate
conversation on the retention of data apparently.
> Note that I personally am a member of many lists, an admin of multiple
> lists and a site admin for multiple mailman installations. I am well
> aware of the frustrations of list admins who wind up just doing it
> because it's way easier than instruction some users as to how to do it
> themselves. However, I don't think that is necessarily sufficient reason
> to hand over control of global, non-list specific user information to
> the admin of one particular list that the user happens to be a member of.
I never asked for global control for list owners. You have made that
almost a necessity with the multiple email address per user account
feature that you brought in. I don't think List owners should have
global control but server owners certainly do. But the rightful
avoidance of such control for List owners, I think has resulted in a
wrongful limiting of what they can do currently.
I so disagree with S. Turnbull's disparaging comments that I think we
ought to be designing for List owners primarily and not list
members/users when it comes to user interfaces. From what I see, it is
mostly server and list owners that are interacting with this
(mailman-user) list and not list members/users. In my experience, I
never hear from list members. Just list owners. Whatever issue list
owners have with their own list members are easily handled by them when
it comes to Mailman 2. Not so much with Mailman 3.
>
> Even in mailman 2.1, while a list admin could go to a user's options
> page for the list and change things, the "change globally" check boxes
> only worked for the user, not for the list admin.
>
--
Brian Carpenter
Harmonylists.com
Emwd.com
4 years, 7 months

[MM3-users] Re: signup / registration error - permissions and cert chains
by David Newman
On Dec 31, 2021, at 03:43, Victoriano Giralt <victoriano(a)uma.es> wrote:
>
> 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.
Hi Victoriano,
Thanks for this. I could use some clarification on what specific changes you are suggesting. I *think* you are saying to remove the EMAIL_USE_TLS stuff and also move to another port (maybe 587), but I am not sure.
Also, the reason I added the TLS in the first place was that I was getting errors without it. And I am unclear why the cert / private key pair do not work for Django when they do work OK for Postfix, Nginx, and Dovecot.
Thanks for clarifying — and happy and safe 2022 to you as well!
dn
>
> 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 ?
>
>
>
> _______________________________________________
> 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, 5 months

[MM3-users] Re: Customise Postorius templates?
by Abhilash Raj
> On Feb 7, 2022, at 4:35 AM, Duane Raymond <duane(a)fairsay.com> wrote:
>
> 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.
>>
>
I hadn’t tried it when I sent email, but when I tried it locally on Postorius,
it seems to work for me.
> 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)
Note that you want to copy from “src/postorius/templates” directory to your
"/opt/mailman/mm/custom” directory. It is important that you retain the “postorius”
and “hyperkitty” directories.
Here is what I have in my settings.py:
- 'DIRS': [],
+ 'DIRS': ['/Users/maxking/Documents/mm3/postorius/example_project/templates’],
And here is the structure of the templates directory you are seeing above:
$ tree /Users/maxking/Documents/mm3/postorius/example_project/templates
/Users/maxking/Documents/mm3/postorius/example_project/templates
└── postorius
└── lists
└── summary.html
Note that I am only overriding the Summary page here.
> 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
Note that you don’t want [“BASE_DIR”, “/custom/“] here, the comma is the
wrong value here. The docs I mentioned have a “/“.
Although, it is possible that even “/“ since that needs BASE_DIR to be a
Path datatype and not string.
Easiest thing with least surprise would be to use the full path, atleast to
ensure that template discovery works as expected.
> 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
Since I was running a dev server, it doesn’t need restart, but simply restarting
gunicorn should should do it. You don’t need to restart anything else.
> 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!)
Hope that helps.
--
thanks,
Abhilash Raj (maxking)
3 years, 4 months

[MM3-users] Re: Does hyperkitty show JPEGs in line and what about attachments?
by tlhackque
On 12-Jul-17 12:39, Mark Sapiro wrote:
>
> Also, with respect to Mailman 2.1, if you want the scrubber to preserve
> file names and extensions, set the following in mm_cfg.py
>
> SCRUBBER_DONT_USE_ATTACHMENT_FILENAME = False
> SCRUBBER_USE_ATTACHMENT_FILENAME_EXTENSION = True
>
> and if you want scrubbed HTML to not be HTML escaped so it renders
> rather than looking like raw html, set
>
> ARCHIVE_HTML_SANITIZER = 3
>
> but note this comment from Defaults.py
>
>> # 3 - Remove text/html as attachments but don't HTML-escape them. Note: this
>> # is very dangerous because it essentially means anybody can send an HTML
>> # email to your site containing evil JavaScript or web bugs, or other
>> # nasty things, and folks viewing your archives will be susceptible. You
>> # should only consider this option if you do heavy moderation of your list
>> # postings.
>
> This is an issue with HyperKitty as it appears this is what HyperKitty
> does and there's no way to turn it off.
>
This warning seems a bit dated, though it's not completely wrong. It
comes from the days when HTML was new, browsers were fragile, and
javascript treated with suspicion. And virus/spam scanners for email
were non-existent.
Today, it's a very rare website that doesn't rely on javascript
(Postorious and Hyperkitty use JS). Browsers, while they still have
bugs, are much more defensive. And there are plenty of truly evil sites
that they have to defend against.
It is certainly true that archived e-mail can turn your site into an
unknowing distributor of malware: FLASH bugs, documents with embedded
buffer overflows, cross-site scripting and the other many ills of the
day. Wikis deal with this frequently.
However, in these cases, your mailing list has distributed the same bits
to your subscribers - a community that you probably care more about than
a random visitor to your (open) archive.
I wouldn't run a list - public or private - where the traffic doesn't go
through SPAM and virus filtering before Mailman sees it. (SpamAssassin
and ClamAV are good open-source solutions.) And once you've done that
(and Mailman 3's optional DMARC), most of these attacks are
defanged/mitigated. This is essentially automated moderation - to a point.
Note that all the Djano authentication schemes packaged with Mailman
(facebook, google, etc) rely on javascript and are sites littered with
what the comment refers to as "webbugs" - Google Analytics, tracking
cookies, browser fingerprinting, 0 size images (the original webbug).
They make money (and have become mainstream) using technologies that
were considered anti-social when that warning was written. (Personally,
I still think of them as anti-social, but the public has chosen to pay
for services with privacy...)
While some may elect to stick with the highly restrictive policies of
"plain text only", this limits the information content and applicability
of the the platform. Whether this is acceptable depends on the
community that you serve. Mailman can be an effective mechanism to
deliver rich media on a "push" basis. And that's "rich" by 1980
standards (bold, well-formatted tables, an attached agenda or document
package); not even "rich" by today's (sleeping cat videos...).
I think that Mailman has to be able to handle today's rich media with a
reasonable degree of safety and convenience. Including in the
archives. I thought that was one of the goals for Mailman Version 3...
I also think that the advice quoted above should be modified to better
reflect these realities. Mailman isn't the only tool available to
protect users from evil content, and aggressively filtering to plaintext
is a very blunt instrument. Including anti-spam, anti-virus, DNS
blacklisting, DKIM/DMARC tests in the delivery pipeline (most of which
can be/is done before Mailman touches a post) should be strongly
recommended.
Checks for headers indicating checked-by local (anti-spam/anti-virus)
agents should be available in the Mailman rulesets (and require some
cooperation from the MTA to ensure that they can't be passed through
from outside.)
There is nothing wrong with running a plain text only site, if it serves
your community. But if Mailman wants to be relevant in today's
environment, it has to adapt to rich content as more than an unwelcome
guest. (As I have :0)
7 years, 10 months

[MM3-users] Re: Confirmation emails to Users has wrong domain name (example.com!)
by Odhiambo Washington
On Thu, Sep 30, 2021 at 4:09 PM Abhilash Raj <maxking(a)asynchronous.in>
wrote:
>
>
> 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 did this, but there is still a problem: The hyperkitty URL still shows
example.com.
Maybe I need to re-import the database to clear this?
--
Best regards,
Odhiambo WASHINGTON,
Nairobi,KE
+254 7 3200 0004/+254 7 2274 3223
"Oh, the cruft.", egrep -v '^$|^.*#' :-)
3 years, 8 months

[MM3-users] Re: E-mail every minute: "Cron <www-data@sharky5> ..."
by Odhiambo Washington
On Sun, Jul 7, 2024 at 8:43 PM Robert Heller <heller(a)deepsoft.com> wrote:
> At Sun, 7 Jul 2024 19:48:02 +0300 Odhiambo Washington <odhiambo(a)gmail.com>
> wrote:
>
> >
> > On Sun, Jul 7, 2024 at 7:16 PM Robert Heller <heller(a)deepsoft.com>
> wrote:
> >
> > > At Sun, 7 Jul 2024 18:52:05 +0300 Odhiambo Washington <
> odhiambo(a)gmail.com>
> > > wrote:
> > >
> > > >
> > > > On Sun, Jul 7, 2024 at 4:12 PM Robert
> Heller <heller(a)deepsoft.com>
> > > wrote:
> > > >
> > > > > What am I missing? I *think* I have mailman3 *mostly* setup, but
> there
> > > > > are
> > > > > still some configuration things that are missing, but I am not sure
> > > how to
> > > > > fix
> > > > > them (the docs are NOT clear).
> > > > >
> > > >
> > > > Which docs are you relying on?
> > >
> > > https://docs.mailman3.org/en/latest/config-web.html
> > >
> > > I presume these are the official docs for mailman3 -- maybe they
> aren't?
> > >
> > > >
> > > > How about this -
> > > https://docs.mailman3.org/en/latest/install/virtualenv.html
> > > > ??
> > >
> > > I'm not using a virtual environment. I'm using all native Debian 12
> > > packages,
> > > installed via apt. The virtual environment docs are actually even worse
> > > (even
> > > more confusing).
> >
> >
> > Worse? :-)
>
> Even more confusing. Both sets of docs make various assumptions and don't
> really explain things properly. Like everywhere where "settings.py" is
> mentioned, it really means "/etc/mailman3/mailman-web.py"
>
No! It means /etc/mailman3/settings.py - literally!
> In any case, the virtual environment docs are hard to relate to a "native"
> install and are generally hard to follow, since they seem to jump all over
> the
> place.
When one day you'll be able to internalize what a Python virtual
environment is, you'll realize that it's VERY convenient.
You will actually embrace it from that point onwards.
(Spaghetti docs?) And it is hard to replace the various (and not
> always consistent) virtual environment paths and settings files to the
> "native"
> paths.
Actually, if you're this inclined to run everything natively, MM3 is
perhaps not for you. Why? Because you'll not easily find help here.
We focus on the virtual environment only as the standard.. Why? Because no
one is willing to deal with ALL the OS-centric packaging
out there. Python virtual environment is universal across all the OSes, I
can say.
> The "official" docs are just not useful to me, since I am not using a
> virtual
> environment. If a virtual environment is recomended, what is the point of
> the
> Debian 12 packages?
We cannot answer that here. I guess they are meant for people like you who
strive under pain :-)
With the Python virtual environment, I can install and manage MM3 in almost
any *nix OS.
> Are they just not meant to be used? Really? Do you mean that I should use
> a separate package management system for Mailman3? That
> really sucks.
>
Yes, they are meant to be used. Noone denies that. However, they are not
packaged by the Mailman Developers.
Did you read one response from Mark Sapiro where he said, and I quote:
```
If you prefer to use the Debian packages, that's fine, but if using the
Debian packages, your primary resource for support, documentation, bug
reports, etc. should be Debian. See https://wiki.list.org/x/12812344
```
So yes, go ahead and use the Debian packages. No one is stopping you.
--
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: Digests not working correctly
by Joel Lord
Now I'm on one of the lists in digest mode and I can see that it's a
mess. Periodic digests are definitely NOT working, so I'll lay that out
here.
root@host2:/# cat /etc/cron.d/mailman
# This goes in /etc/cron.d/mailman
# Replace "apache" by your webserver user ("www-data" on Debian systems) and
# set the path to the Django project directory
0 23 * * * lists /usr/local/bin/mailman digests --periodic
0 23 * * * lists /usr/local/bin/mailman notify
root@host2:/# grep digests /var/log/cron.log
Jun 11 23:00:01 host2 CRON[1632765]: (lists) CMD (/usr/local/bin/mailman
digests --periodic)
Jun 12 23:00:01 host2 CRON[2177286]: (lists) CMD (/usr/local/bin/mailman
digests --periodic)
root@host2:/home/members/directory# su - lists
lists@host2:~$ /usr/local/bin/mailman digests --periodic
lists@host2:~$ ls var/lists/<list>/
digest.mmdf
In this case I've got /usr/local/bin/mailman as a symlink to the mailman
binary inside the venv's bin directory, just for simplicity. That
digest.mmdf file is dated June 9th and clearly ought to have been
cleared out on any of the nightly runs between then and today but has
not. There are no errors anywhere I can find.
How can I try and track this down?
-Joel
On 6/4/2023 10:15 PM, Joel Lord wrote:
> 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
1 year, 11 months

[MM3-users] Re: psycopg2 error?
by Odhiambo Washington
On Fri, Oct 27, 2023 at 4:38 AM Mark Sapiro <mark(a)msapiro.net> wrote:
> On 10/26/23 01:03, Odhiambo Washington wrote:
> >
> > <CUT>
> > root@debian12:/home/wash# systemctl status mailman3.service
> > × mailman3.service - GNU Mailing List Manager
> > Loaded: loaded (/etc/systemd/system/mailman3.service; enabled;
> preset:
> > enabled)
> > Active: failed (Result: exit-code) since Thu 2023-10-26 09:36:41
> EAT;
> > 8s ago
> > Process: 1893842 ExecStart=/opt/mailman/venv/bin/mailman start
> > (code=exited, status=1/FAILURE)
> > CPU: 789ms
> >
> > Oct 26 09:36:41 debian12.wash.lan mailman[1893842]: dbapi =
> > dbapi_meth(**dbapi_args)
> > Oct 26 09:36:41 debian12.wash.lan mailman[1893842]:
> > ^^^^^^^^^^^^^^^^^^^^^^^^
> > Oct 26 09:36:41 debian12.wash.lan mailman[1893842]: File
> >
> "/opt/mailman/venv/lib/python3.11/site-packages/sqlalchemy/dialects/postgresql/psycopg2.py",
> > line 690, in import_dbapi
> > Oct 26 09:36:41 debian12.wash.lan mailman[1893842]: import psycopg2
> > Oct 26 09:36:41 debian12.wash.lan mailman[1893842]: File
> > "/opt/mailman/venv/lib/python3.11/site-packages/psycopg2/__init__.py",
> line
> > 51, in <module>
> > Oct 26 09:36:41 debian12.wash.lan mailman[1893842]: from
> > psycopg2._psycopg import ( # noqa
> > Oct 26 09:36:41 debian12.wash.lan mailman[1893842]: SystemError:
> > initialization of _psycopg raised unreported exception
> > Oct 26 09:36:41 debian12.wash.lan systemd[1]: mailman3.service: Control
> > process exited, code=exited, status=1/FAILURE
> > Oct 26 09:36:41 debian12.wash.lan systemd[1]: mailman3.service: Failed
> with
> > result 'exit-code'.
> > Oct 26 09:36:41 debian12.wash.lan systemd[1]: Failed to start
> > mailman3.service - GNU Mailing List Manager.
> > </CUT>
>
> Is your database PostgreSQL or some other? If it's not PostgreSQL, see
> the thread at
>
> https://lists.mailman3.org/archives/list/mailman-users@mailman3.org/thread/…
> - particularly
>
> https://lists.mailman3.org/archives/list/mailman-users@mailman3.org/message…
>
> Also see
>
> https://docs.mailman3.org/en/latest/install/virtualenv.html#installing-mail…
> where it now says in part "This will install latest release of Mailman
> Core, and Python bindings for Postgresql database. If you are using a
> different database manager, do not install psycopg2-binary."
>
So my database is PostgreSQL-15:
```
postgres@debian12:~$ psql
psql (15.3 (Debian 15.3-0+deb12u1))
Type "help" for help.
postgres=#
```
Below is the output of `mailman info` which for some reason I forgot to
attach in the initial post. Maybe it contains something useful?
```
(venv) mailman@debian12:~$ mailman info
Traceback (most recent call last):
File "/opt/mailman/venv/bin/mailman", line 33, in <module>
sys.exit(load_entry_point('mailman==3.3.9', 'console_scripts',
'mailman')())
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/mailman/venv/lib/python3.11/site-packages/click/core.py", line
1157, in __call__
return self.main(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/mailman/venv/lib/python3.11/site-packages/click/core.py", line
1077, in main
with self.make_context(prog_name, args, **extra) as ctx:
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/mailman/venv/lib/python3.11/site-packages/click/core.py", line
943, in make_context
self.parse_args(ctx, args)
File "/opt/mailman/venv/lib/python3.11/site-packages/click/core.py", line
1644, in parse_args
rest = super().parse_args(ctx, args)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/mailman/venv/lib/python3.11/site-packages/click/core.py", line
1408, in parse_args
value, args = param.handle_parse_result(ctx, opts, args)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/mailman/venv/lib/python3.11/site-packages/click/core.py", line
2400, in handle_parse_result
value = self.process_value(ctx, value)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/mailman/venv/lib/python3.11/site-packages/click/core.py", line
2362, in process_value
value = self.callback(ctx, self, value)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File
"/opt/mailman/venv/lib/python3.11/site-packages/mailman/bin/mailman.py",
line 95, in initialize_config
initialize(value)
File
"/opt/mailman/venv/lib/python3.11/site-packages/mailman/core/initialize.py",
line 229, in initialize
initialize_2(propagate_logs=propagate_logs)
File
"/opt/mailman/venv/lib/python3.11/site-packages/mailman/core/initialize.py",
line 187, in initialize_2
config.db = getUtility(IDatabaseFactory, utility_name).create()
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File
"/opt/mailman/venv/lib/python3.11/site-packages/mailman/database/factory.py",
line 57, in create
database.initialize()
File
"/opt/mailman/venv/lib/python3.11/site-packages/mailman/database/base.py",
line 117, in initialize
self.engine = create_engine(
^^^^^^^^^^^^^^
File "<string>", line 2, in create_engine
File
"/opt/mailman/venv/lib/python3.11/site-packages/sqlalchemy/util/deprecations.py",
line 281, in warned
return fn(*args, **kwargs) # type: ignore[no-any-return]
^^^^^^^^^^^^^^^^^^^
File
"/opt/mailman/venv/lib/python3.11/site-packages/sqlalchemy/engine/create.py",
line 601, in create_engine
dbapi = dbapi_meth(**dbapi_args)
^^^^^^^^^^^^^^^^^^^^^^^^
File
"/opt/mailman/venv/lib/python3.11/site-packages/sqlalchemy/dialects/postgresql/psycopg2.py",
line 690, in import_dbapi
import psycopg2
File
"/opt/mailman/venv/lib/python3.11/site-packages/psycopg2/__init__.py", line
51, in <module>
from psycopg2._psycopg import ( # noqa
SystemError: initialization of _psycopg raised unreported exception
```
--
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: moving lists to another server
by Odhiambo Washington
On Mon, Nov 20, 2023 at 8:53 PM Mark Sapiro <mark(a)msapiro.net> wrote:
> On 11/20/23 00:58, Odhiambo Washington wrote:
> >
> > 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'.
>
> Normally you do this on the old server via the HyperKitty web UI which
> has download buttons which do things like
>
>
> https://example.com/archives/list/list@example.com/export/list@example.com.…
>
> or for a partial archive
>
>
> https://example.com/archives/list/list@example.com/export/list@example.com-…
>
> However, in your case I don't think you have the old installation working
> any more so the above won't help.
>
I had a dump of the old installation actually - both databases.
The above has actually helped and I obtained the archive.
> > BTW, how will ' mailman addmembers' treat a file containing:
> > ```
> > Firstname Lastname <email@address>
> > Onlyname <email2@address>
> > ```
>
> Correctly. It will import email@address with display name = 'Firstname
> Lastname' and email2@address with display name = 'Onlyname'.
>
Super!
> > 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.
>
> Perhaps you can export the mbox via the web UI on the old server or
> maybe temporarily create a second mailman-web on your server with the
> old mailman-web database and use that web UI.
That's exactly how I did it and got the archives.
> Otherwise, if you have a working mailman-web that can access this
> database, you could try
> something like
> ```
> $ mailman-web shell
>
> >>> from hyperkitty.lib.compat import get_list_by_name
> >>> mlist = get_list_by_name('list_name_only', 'list_domain')
> >>> with open('output.mbox', 'wb') as fp:
> ... for email in mlist.emails.order_by("archived_date").all():
> ... fp.write(email.as_bytes() + b'\n')
> ...
> >>>
> ```
>
I tested the above out of curiosity. It failed. There are 9 lists in the
setup, but I am only interested in 1.
```
(venv) mailman@debian12:~$ mailman-web shell
Python 3.11.2 (main, Mar 13 2023, 12:18:29) [GCC 12.2.0]
Type 'copyright', 'credits' or 'license' for more information
IPython 8.17.2 -- An enhanced Interactive Python. Type '?' for help.
In [1]: from hyperkitty.lib.compat import get_list_by_name
In [2]: mlist = get_list_by_name('list_name_only', 'list_domain')
---------------------------------------------------------------------------
Http404 Traceback (most recent call last)
Cell In[2], line 1
----> 1 mlist = get_list_by_name('list_name_only', 'list_domain')
File ~/venv/lib/python3.11/site-packages/hyperkitty/lib/compat.py:37, in
get_list_by_name(list_name, domain)
35 matching =
list(MailingList.objects.filter(name__startswith=list_name+"@"))
36 if len(matching) == 0: # no candidate found
---> 37 raise Http404("No archived mailinglist by that name")
38 if len(matching) == 1: # only one candidate
39 return matching[0]
Http404: No archived mailinglist by that name
```
Was I supposed to substitute something for the real listname of the list I
wanted?
Another thing - totally unrelated - that surprised me:
While using the commented-out block below, I could not click and get
anything beyond http://http://list.name/mailman3 as anything to do with
/postorius/xxxxx gave "Page not found" error.
However, with the second config block that uses the UNIX socket, I am able
to access everything
```
#<IfModule mod_proxy.c>
# ProxyPreserveHost On
# ProxyPass "/mailman3" "http://127.0.0.1:8010/mailman3"
# ProxyPass "/archives" "http://127.0.0.1:8010/archives"
# ProxyPass "/accounts" "http://127.0.0.1:8010/accounts"
# ProxyPass "/admin" "http://127.0.0.1:8010/admin"
# ProxyPass "/user-profile" "http://127.0.0.1:8010/user-profile"
# </IfModule>
ProxyPassMatch ^/static/ !
ProxyPassMatch ^/favicon.ico !
ProxyPass / unix:/opt/mailman/mm/var/uwsgi.sock|uwsgi://localhost/
ProxyPassReverse / unix:/opt/mailman/mm/var/uwsgi.sock|uwsgi://localhost/
```
Why is it that the UNIX socket option worked flawlessly while the other
option failed???
--
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, 6 months

[MM3-users] Re: Migrating mailman3 to latest ubuntu lts
by Helio Loureiro
Hi,
No luck :(
(venv) mailman@new-server ~ (v3.3.9)> *pip freeze | egrep
"mailman-web|django-mailman3|django-allauth"*
django-allauth==0.59.0
django-mailman3==1.3.11
mailman-web==0.0.8
(venv) mailman@new-server ~ (v3.3.9)> *pip install -U
django-allauth==0.58.0*
Collecting django-allauth==0.58.0
Downloading django-allauth-0.58.0.tar.gz (861 kB)
---------------------------------------- 861.7/861.7 KB 9.4 MB/s eta
0:00:00
Installing build dependencies ... done
Getting requirements to build wheel ... done
Installing backend dependencies ... done
Preparing metadata (pyproject.toml) ... done
Requirement already satisfied: requests-oauthlib>=0.3.0 in
./venv/lib/python3.10/site-packages (from django-allauth==0.58.0) (1.3.1)
Requirement already satisfied: Django>=3.2 in
./venv/lib/python3.10/site-packages (from django-allauth==0.58.0) (4.1.13)
Requirement already satisfied: pyjwt[crypto]>=1.7 in
./venv/lib/python3.10/site-packages (from django-allauth==0.58.0) (2.8.0)
Requirement already satisfied: requests>=2.0.0 in
./venv/lib/python3.10/site-packages (from django-allauth==0.58.0) (2.31.0)
Requirement already satisfied: python3-openid>=3.0.8 in
./venv/lib/python3.10/site-packages (from django-allauth==0.58.0) (3.2.0)
Requirement already satisfied: asgiref<4,>=3.5.2 in
./venv/lib/python3.10/site-packages (from
Django>=3.2->django-allauth==0.58.0) (3.7.2)
Requirement already satisfied: sqlparse>=0.2.2 in
./venv/lib/python3.10/site-packages (from
Django>=3.2->django-allauth==0.58.0) (0.4.4)
Requirement already satisfied: cryptography>=3.4.0 in
./venv/lib/python3.10/site-packages (from
pyjwt[crypto]>=1.7->django-allauth==0.58.0) (41.0.7)
Requirement already satisfied: defusedxml in
./venv/lib/python3.10/site-packages (from
python3-openid>=3.0.8->django-allauth==0.58.0) (0.7.1)
Requirement already satisfied: urllib3<3,>=1.21.1 in
./venv/lib/python3.10/site-packages (from
requests>=2.0.0->django-allauth==0.58.0) (2.1.0)
Requirement already satisfied: charset-normalizer<4,>=2 in
./venv/lib/python3.10/site-packages (from
requests>=2.0.0->django-allauth==0.58.0) (3.3.2)
Requirement already satisfied: idna<4,>=2.5 in
./venv/lib/python3.10/site-packages (from
requests>=2.0.0->django-allauth==0.58.0) (3.6)
Requirement already satisfied: certifi>=2017.4.17 in
./venv/lib/python3.10/site-packages (from
requests>=2.0.0->django-allauth==0.58.0) (2023.11.17)
Requirement already satisfied: oauthlib>=3.0.0 in
./venv/lib/python3.10/site-packages (from
requests-oauthlib>=0.3.0->django-allauth==0.58.0) (3.2.2)
Requirement already satisfied: typing-extensions>=4 in
./venv/lib/python3.10/site-packages (from
asgiref<4,>=3.5.2->Django>=3.2->django-allauth==0.58.0) (4.9.0)
Requirement already satisfied: cffi>=1.12 in
./venv/lib/python3.10/site-packages (from
cryptography>=3.4.0->pyjwt[crypto]>=1.7->django-allauth==0.58.0) (1.16.0)
Requirement already satisfied: pycparser in
./venv/lib/python3.10/site-packages (from
cffi>=1.12->cryptography>=3.4.0->pyjwt[crypto]>=1.7->django-allauth==0.58.0)
(2.21)
Building wheels for collected packages: django-allauth
Building wheel for django-allauth (pyproject.toml) ... done
Created wheel for django-allauth:
filename=django_allauth-0.58.0-py3-none-any.whl size=1157319
sha256=a430c552101d1ad47bc00b16d1c1d6df728afacdd13823927b4cbfb02c35dbfc
Stored in directory:
/local/mailman/.cache-ubuntu-22.04/pip/wheels/55/0a/79/e199827a18f310906c2a90b0e92b89c41daf21d2a502db6710
Successfully built django-allauth
Installing collected packages: django-allauth
Attempting uninstall: django-allauth
Found existing installation: django-allauth 0.59.0
Uninstalling django-allauth-0.59.0:
Successfully uninstalled django-allauth-0.59.0
Successfully installed django-allauth-0.58.0
(venv) mailman@new-server ~ (v3.3.9)> *mailman-web migrate*
System check identified some issues:
WARNINGS:
account.EmailAddress: (models.W036) MariaDB does not support unique
constraints with conditions.
HINT: A constraint won't be created. Silence this warning if you don't care
about it.
account.EmailAddress: (models.W043) MariaDB does not support indexes on
expressions.
HINT: An index won't be created. Silence this warning if you don't care
about it.
Operations to perform:
Apply all migrations: account, admin, auth, contenttypes,
django_mailman3, django_q, hyperkitty, postorius, sessions, sites,
socialaccount
Running migrations:
Applying account.0004_alter_emailaddress_drop_unique_email...Traceback
(most recent call last):
File
"/local/mailman/venv/lib/python3.10/site-packages/django/db/backends/utils.py",
line 89, in _execute
return self.cursor.execute(sql, params)
File
"/local/mailman/venv/lib/python3.10/site-packages/django/db/backends/mysql/base.py",
line 75, in execute
return self.cursor.execute(query, args)
File
"/local/mailman/venv/lib/python3.10/site-packages/MySQLdb/cursors.py", line
179, in execute
res = self._query(mogrified_query)
File
"/local/mailman/venv/lib/python3.10/site-packages/MySQLdb/cursors.py", line
330, in _query
db.query(q)
File
"/local/mailman/venv/lib/python3.10/site-packages/MySQLdb/connections.py",
line 257, in query
_mysql.connection.query(self, query)
MySQLdb.OperationalError: (2013, 'Lost connection to MySQL server during
query')
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/local/mailman/venv/bin/mailman-web", line 8, in <module>
sys.exit(main())
File
"/local/mailman/venv/lib/python3.10/site-packages/mailman_web/manage.py",
line 90, in main
execute_from_command_line(sys.argv)
File
"/local/mailman/venv/lib/python3.10/site-packages/django/core/management/__init__.py",
line 446, in execute_from_command_line
utility.execute()
File
"/local/mailman/venv/lib/python3.10/site-packages/django/core/management/__init__.py",
line 440, in execute
self.fetch_command(subcommand).run_from_argv(self.argv)
File
"/local/mailman/venv/lib/python3.10/site-packages/django/core/management/base.py",
line 402, in run_from_argv
self.execute(*args, **cmd_options)
File
"/local/mailman/venv/lib/python3.10/site-packages/django/core/management/base.py",
line 448, in execute
output = self.handle(*args, **options)
File
"/local/mailman/venv/lib/python3.10/site-packages/django/core/management/base.py",
line 96, in wrapped
res = handle_func(*args, **kwargs)
File
"/local/mailman/venv/lib/python3.10/site-packages/django/core/management/commands/migrate.py",
line 349, in handle
post_migrate_state = executor.migrate(
File
"/local/mailman/venv/lib/python3.10/site-packages/django/db/migrations/executor.py",
line 135, in migrate
state = self._migrate_all_forwards(
File
"/local/mailman/venv/lib/python3.10/site-packages/django/db/migrations/executor.py",
line 167, in _migrate_all_forwards
state = self.apply_migration(
File
"/local/mailman/venv/lib/python3.10/site-packages/django/db/migrations/executor.py",
line 252, in apply_migration
state = migration.apply(state, schema_editor)
File
"/local/mailman/venv/lib/python3.10/site-packages/django/db/migrations/migration.py",
line 130, in apply
operation.database_forwards(
File
"/local/mailman/venv/lib/python3.10/site-packages/django/db/migrations/operations/fields.py",
line 235, in database_forwards
schema_editor.alter_field(from_model, from_field, to_field)
File
"/local/mailman/venv/lib/python3.10/site-packages/django/db/backends/base/schema.py",
line 788, in alter_field
self._alter_field(
File
"/local/mailman/venv/lib/python3.10/site-packages/django/db/backends/base/schema.py",
line 858, in _alter_field
self.execute(self._delete_unique_sql(model, constraint_name))
File
"/local/mailman/venv/lib/python3.10/site-packages/django/db/backends/base/schema.py",
line 199, in execute
cursor.execute(sql, params)
File
"/local/mailman/venv/lib/python3.10/site-packages/django/db/backends/utils.py",
line 67, in execute
return self._execute_with_wrappers(
File
"/local/mailman/venv/lib/python3.10/site-packages/django/db/backends/utils.py",
line 80, in _execute_with_wrappers
return executor(sql, params, many, context)
File
"/local/mailman/venv/lib/python3.10/site-packages/django/db/backends/utils.py",
line 84, in _execute
with self.db.wrap_database_errors:
File
"/local/mailman/venv/lib/python3.10/site-packages/django/db/utils.py", line
91, in __exit__
raise dj_exc_value.with_traceback(traceback) from exc_value
File
"/local/mailman/venv/lib/python3.10/site-packages/django/db/backends/utils.py",
line 89, in _execute
return self.cursor.execute(sql, params)
File
"/local/mailman/venv/lib/python3.10/site-packages/django/db/backends/mysql/base.py",
line 75, in execute
return self.cursor.execute(query, args)
File
"/local/mailman/venv/lib/python3.10/site-packages/MySQLdb/cursors.py", line
179, in execute
res = self._query(mogrified_query)
File
"/local/mailman/venv/lib/python3.10/site-packages/MySQLdb/cursors.py", line
330, in _query
db.query(q)
File
"/local/mailman/venv/lib/python3.10/site-packages/MySQLdb/connections.py",
line 257, in query
_mysql.connection.query(self, query)
django.db.utils.OperationalError: (2013, 'Lost connection to MySQL server
during query')
(venv) mailman@new-server ~ (v3.3.9) [0|1]> *more /etc/mailman3/settings.py*
# Mailman Web configuration file.
# /etc/mailman3/settings.py
# Get the default settings.
from mailman_web.settings.base import *
from mailman_web.settings.mailman import *
# Settings below supplement or override the defaults.
#: Default list of admins who receive the emails from error logging.
ADMINS = (
('Mailman Suite Admin', 'root@localhost'),
)
# Postgresql database setup.
DATABASES = {
'default': {
'ENGINE': 'django.db.backends.mysql',
'NAME': 'mailman3web',
'USER': 'mailman3web',
# TODO: Replace this with the password.
'PASSWORD': '***********',
'HOST': 'localhost',
# PORT: set to empty string for default.
'PORT': '3306',
# OPTIONS: Extra parameters to use when connecting to the database.
#'OPTIONS': {
# Set sql_mode to 'STRICT_TRANS_TABLES' for MySQL. See
# https://docs.djangoproject.com/en/1.11/ref/
# databases/#setting-sql-mode
# 'init_command': "SET sql_mode='STRICT_TRANS_TABLES'",
# 'charset': 'utf8mb4',
#},
}
}
# 'collectstatic' command will copy all the static files here.
# Alias this location from your webserver to `/static`
STATIC_ROOT = '/local/mailman/web/static'
# enable the 'compress' command.
COMPRESS_ENABLED = True
# Make sure that this directory is created or Django will fail on start.
LOGGING['handlers']['file']['filename'] =
'/local/mailman/web/logs/mailmanweb.log'
#: See https://docs.djangoproject.com/en/dev/ref/settings/#allowed-hosts
ALLOWED_HOSTS = [
"localhost", # Archiving API from Mailman, keep it.
"127.0.0.1",
# "lists.your-domain.org",
# Add here all production domains you have.
"*"
]
#: See
https://docs.djangoproject.com/en/dev/ref/settings/#csrf-trusted-origins
(venv) mailman@new-server ~ (v3.3.9)> *mysql -umailman3web -p -h localhost
mailman3web*
Enter password:
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A
Welcome to the MariaDB monitor. Commands end with ; or \g.
Your MariaDB connection id is 32
Server version: 10.6.12-MariaDB-0ubuntu0.22.04.1 Ubuntu 22.04
Copyright (c) 2000, 2018, Oracle, MariaDB Corporation Ab and others.
Type 'help;' or '\h' for help. Type '\c' to clear the current input
statement.
MariaDB [mailman3web]> show tables;
+-------------------------------+
| Tables_in_mailman3web |
+-------------------------------+
| account_emailaddress |
| account_emailconfirmation |
| auth_group |
| auth_group_permissions |
| auth_permission |
| auth_user |
| auth_user_groups |
| auth_user_user_permissions |
| django_admin_log |
| django_content_type |
| django_mailman3_maildomain |
| django_mailman3_profile |
| django_migrations |
| django_q_ormq |
| django_q_schedule |
| django_q_task |
| django_session |
| django_site |
| hyperkitty_attachment |
| hyperkitty_email |
| hyperkitty_favorite |
| hyperkitty_lastview |
| hyperkitty_mailinglist |
| hyperkitty_profile |
| hyperkitty_sender |
| hyperkitty_tag |
| hyperkitty_tagging |
| hyperkitty_thread |
| hyperkitty_threadcategory |
| hyperkitty_vote |
| socialaccount_socialaccount |
| socialaccount_socialapp |
| socialaccount_socialapp_sites |
| socialaccount_socialtoken |
+-------------------------------+
34 rows in set (0.000 sec)
Best Regards,
Helio Loureiro
https://helio.loureiro.eng.br
https://github.com/helioloureiro
https://mastodon.social/@helioloureiro
On Mon, 18 Dec 2023 at 17:11, Mark Sapiro <mark(a)msapiro.net> wrote:
> On 12/18/23 6:24 AM, Helio Loureiro wrote:
> > Hi,
> >
> > Indeed it was the configuration. It was placed into
> > /etc/mailman3/mailman-web.py. After a I changed to
> > /etc/mailman3/settings.py a few things advanced a little bit more.
> >
> > I had to figure out how to fix mysqlclient installation since there
> isn't a
> > mention about it and the simple "pip install mysqclient" was breaking
> with
> > pkg-config issues. But it did work at the end.
> >
> > Now I can see further messages on mailman3-web than before.
> >
> > (venv) mailman@new-server ~ (v3.3.9)> mailman-web migrate
> > System check identified some issues:
> >
> > WARNINGS:
> > account.EmailAddress: (models.W036) MariaDB does not support unique
> > constraints with conditions.
> > HINT: A constraint won't be created. Silence this warning if you don't
> care
> > about it.
> > account.EmailAddress: (models.W043) MariaDB does not support indexes on
> > expressions.
> > HINT: An index won't be created. Silence this warning if you don't care
> > about it.
> > Operations to perform:
> > Apply all migrations: account, admin, auth, contenttypes,
> > django_mailman3, django_q, hyperkitty, postorius, sessions, sites,
> > socialaccount
> > Running migrations:
> > Applying account.0004_alter_emailaddress_drop_unique_email...Traceback
> > (most recent call last):
>
>
> I'm not sure why there would be an issue with this migration, but there
> is a possible compatibility issue depending on how you installed things.
>
> django-mailman3<=1.3.11 is not compatible with django-allauth>=0.58.
>
> In your venv, try
> ```
> pip install django-allauth\<0.58
> ```
>
> --
> 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 helio(a)loureiro.eng.br
>
1 year, 5 months

[MM3-users] Re: Apache+mod_wsgi issue
by Odhiambo Washington
On Sat, Dec 24, 2022 at 9:40 PM Mark Sapiro <mark(a)msapiro.net> wrote:
> On 12/24/22 00:00, Odhiambo Washington wrote:
> >
> > These are my files:
> > 1. urls.py
> > <CUT >
> > from django.conf.urls import include
> > from django.urls import re_path
> > from django.contrib import admin
> > from django.urls import reverse_lazy
> > 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),
> > re_path(r'^mailman3/', include('postorius.urls')),
> > re_path(r'^archives/', include('hyperkitty.urls')),
> > ]
> > </CUT>
>
>
> You don't need all of those. ^postorius/ and ^mailman3/ are two
> different ways to access Postorius, and ^hyperkitty/ and ^archives/ are
> two different ways to access HypereKitty. You only need one of each, but
> having both is OK.
>
That urls.py was picked from
https://wiki.list.org/DOC/Mailman%203%20installation%20experience.
Maybe that page needs some edits/revision now?
> 2. apache.conf
> > <CUT>
> > ...
> > Alias /static "/opt/mailman/mm/static"
> > <Directory "/opt/mailman/mm/static">
> > Require all granted
> > </Directory>
> > # WSGIScriptAlias /mailman3 /opt/mailman/mm/wsgi.py
> > # WSGIScriptAlias /accounts /opt/mailman/mm/wsgi.py
> > # WSGIScriptAlias /admin /opt/mailman/mm/wsgi.py
> > # WSGIScriptAlias /archives /opt/mailman/mm/wsgi.py
> > # WSGIScriptAlias /user-profile /opt/mailman/mm/wsgi.py
> > # WSGIScriptAlias /hyperkitty /opt/mailman/mm/wsgi.py
> > # WSGIScriptAlias /postorius /opt/mailman/mm/wsgi.py
> > WSGIScriptAlias / /opt/mailman/mm/wsgi.py
>
>
> This will send every http request to mod_wsgi except for requests to
> /static. This is OK if there are no other web sites on this server and
> the only http requests are for Django related things.
>
This is just a virtual host. There are other websites on the server.
...
> > I have tested with creating all those commented out aliases and that
> ended
> > up still giving me /mailman3/mailman3/* which I did not
> > like, although everything appeared to work.
> > I then ended up with only "WSGIScriptAlias / /opt/mailman/mm/wsgi.py"
> > and now when I type https://mm3-lists.kictanet.or.ke I end
> > up at https://mm3-lists.kictanet.or.ke/mailman3/lists/. Of course
> something
> > has appended "/mailman3"
> > So this has resulted in all URLs having /mailman3/ appended, except for
> the
> > /archives link.
>
>
> How about https://mm3-lists.kictanet.or.ke/user_profile/ ?
>
I have uncommented the line "WSGIScriptAlias /user-profile
/opt/mailman/mm/wsgi.py",
I don't see any definition for it in urls.py as well. Perhaps that's the
issue?
When I uncomment /user-profile, I end up with an ugly URL:
https://mm3-lists.kictanet.or.ke/user-profile/user-profile/
So instead of aliasing the /user-profile, I have decided to add another
definition to urls.py:
re_path(r'^user-profile/', include('allauth.urls')),
Which I think gives me a cleaner URL:
https://mm3-lists.kictanet.or.ke/user-profile/login/?next=/user-profile/
I also had to alias /accounts, which then brings me to:
https://mm3-lists.kictanet.or.ke/accounts/mailman3/lists/ - which I believe
is fine because one gets the
option to either login or signup.
And I think that "/account" and "/user-profile" are synonymous.
> Now my question is about what could be adding the /mailman3. Is it
> possible
> > that I installed something out of the ordinary?
>
>
> It's a mod_wsgi thing. I haven't used mod_wsgi for Mailman for some time
> (I now use gunicorn on all the sites I manage), but when I did I think I
> had
> WSGIScriptAlias /mm3 /opt/mailman/mm/wsgi.py
>
> and all the URLs were like https://example.com/mm3/mailman3/...,
> https://example.com/mm3/archives/..., etc.
>
I already had gunicorn working too, but I just need to also figure out this
mod_wsgi.
I will stop bothering about the /mailman3 being appended, as long as it
serves the required purpose.
Thank you for all the help.
--
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: hello, Discussion on how to subscribe to the mailing list
by Stephen J. Turnbull
Mark Sapiro writes:
> On 1/16/23 18:55, 朱超 wrote:
> > Hi, When I subscribe the email list in Subscription Policy is
> > confirm, Some problems happen in here:
> > 1.Some mail mua reject send the confirm the message, because the
> > length of recipient is too long. for exmaple:
> > requirements-confirm+9605556e0b35a5da280c1de0d34a3e6f770f8ea5@domain,
> > and the mail mua reject to modify about this.
>
> The default English template says in part:
>
> Before you can start using GNU Mailman at this site, you must first
> confirm that this is your email address. You can do this by replying to
> this message.
>
> Or you should include the following line -- and only the following
> line -- in a message to $request_email:
>
> confirm $token
>
> I.e. It gives an alternative method if `reply` doesn't work. You can
> provide a custom version of this template with different wording if you
> think you can improve it.
The problem is the reply address, though. Changing the template to
suggest only the "confirm $token" in body method doesn't help people
who hit R expecting that should work, especially since many "user
fiendly" (misspelling intentional) MUAs don't display the address.
Avoiding that requires code changes, I guess?
> > 2.It is inconvenient for users to use. Many people will
> > mistakenly think that after clicking the subscribe button, it
> > will be successful, and they will not process the email.
> step, you can set Subscription Policy to Open, but then anyone can
> maliciously subscribe third parties to the list.
*Please* do not do this if your server is exposed to the Internet.
There are bots that search for such servers, and sell lists of them to
people who want to DOS mailboxes. You may find yourself banned across
the Internet.
The only real alternative to confirmation is approval by moderators.
I believe Mailman 3 offers that alternative as Mailman 2 did, can't
check at the moment.
> > Regarding the discussion on the subscription method of the
> > mailing list, should we consider optimizing the subscription
> > method of the mailing list, for example:
> > 1. use the method of sending a verification code to subscribe by
> > email,When you receive the verification code sent by the
> > mailing list and fill it in again, you can subscribe
> > successfully。
>
> How is this different from the present method.
Just wording. I think they are thinking of the "invite" option that
was provided in Mailman 2 mass subscribe (again, I think Mailman 3
retains it but I never ever used it so I don't recall for sure). But
it doesn't make sense for a user-initiated interaction.
> If you want, you can make
> a custom template and include something like:
>
> Alternatively, you can confirm by going to the URL
>
> https://www.example.com/mailman3/lists/$list_id/confirm/?token=$token
If I understand the OP's PoV correctly, I think I would change the
list information page to say "Send a personal invitation to join the
list to [email address here]. If you aren't a subscriber, you can
invite yourself." And change the word "confirm" in the confirmation
template to "subscribe".
> We don't include that in the default template because Mailman core
> doesn't know if you even have a web UI or how to access it if you
> do.
We should fix that, at least if the web interface is Postorius
(wishlist, assigned to me):
https://gitlab.com/mailman/mailman/-/issues/1055
@mark
https://gitlab.com/mailman/mailman/-/issues/901
Maybe we can close this? I'm not sure why it was left open since
there's no action proposed for Mailman improvement.
> > 2. use the email to send a connection to confirm the
> > subscription,People click the link to be redirected to a
> > confirmation page to subscribe to the email。
>
> See above.
Indeed, AFAICS almost everything the OP is suggesting amounts to an
identical procedure as far as the Mailman server is concerned, it's
just described to the subscriber differently. The one exception is
the suggestion to eliminate the confirmation step, and while that is
supported, it's quite likely to cause problems for third parties and
eventually for the Mailman site unless you have an alternative ground
source of truth such as an employee database.
Steve
2 years, 4 months

[MM3-users] Re: Postorius claims 2 messages held when there are none - out of sync
by Ken Alker
--On Monday, June 26, 2023 8:24 AM -0700 Mark Sapiro <mark(a)msapiro.net>
wrote:
> On 6/26/23 12:01 AM, Ken Alker wrote:
>> When I view a list via Postorius the "Held Messages" menu item has an
>> inverse-red-"2" next to it, as if there are two held messages. There
>> are, in fact, no messages in "/opt/mailman/mm/var/queue/*" (assuming the
>> held messages should be in "pipeline" subdirectory). When I click on
>> "Held Messages" I get "Something went wrong" followed by "HTTP Error
>> 500: {"title": "500 Internal Server Error"}". How do I fix this?
>
> The held messages are not in any queue. They are stored in Mailman's
> var/messages/ hierarchy. They can be examined with `mailman qfile`
Is the var/messages hierarchy also where all the archived emails are stored
for future viewing via the web interface?
> Also, there is a long thread at
> https://lists.mailman3.org/archives/list/mailman-users@mailman3.org/threa
> d/UWCUQYU7Q5X5LWNII57ZZ4DDXE4DEFX7/ and maybe others that might be
> relevant.
I have never used the mailman shell before, but based on the referenced
thread I learned to do this (note that the thread also taught me how to
rewrite it to narrow down to just the list with issues so I didn't delete
held messages in other lists, if my case):
for verification:
venv) mailman@speedy:~/web/logs$ mailman shell -l
sbarc-list(a)lists.netlojix.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 sbarc-list(a)lists.netlojix.com mailing list
>>> requests = IListRequests(m)
>>> first = True
>>> for request in requests.held_requests:
... key, data = requests.get_request(request.id)
... if first:
... first = False
... print(m.list_id)
... print (f"""\
... Sender: {data['_mod_sender']}
... Subject: {data['_mod_subject']}
... Date: {data['_mod_hold_date']}
... Reason: {data['_mod_reason']}
... """)
...
and then to delete the two messages:
(venv) mailman@speedy:~/web/logs$ mailman shell -l
sbarc-list(a)lists.netlojix.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 sbarc-list(a)lists.netlojix.com mailing list
>>> requests = IListRequests(m)
>>> first = True
>>> for request in requests.held_requests:
... key, data = requests.get_request(request.id)
... if first:
... first = False
... print(m.list_id)
... print(f'request id: {request.id}, deleting')
... requests.delete_request(request.id)
...
sbarc-list.lists.netlojix.com
request id: 27, deleting
request id: 28, deleting
>>>
The result of this, however, was that the web interface still claimed I had
two held messages. I wasn't sure if there was some cron-type "sweeper"
process I had to wait to auto-run or if I had to manually do something to
create an update. I then realized that the sample script had a ' >>>
commit ()" ' at the end, which I'd missed. So, I re-entered the script
(but it didn't spit out that it deleted anything this time) and got an
error when I did the commit. So, I figured the messages HAD been delete
and the commit wasn't really necessary. When I went back to the web
interface, the number of held messages was at 0 and I no longer get the
original error when clicking on "Held messages", so my issue is solved.
But this does leave me with some educational questions:
1) Did I affect something somehow with my "commit", or was there a job that
cleaned things up (if so, what job)?
2) Is the "commit" even necessary (I saw it in someone else's script in the
thread)?
3) Is there a way to save a script and then execute it via shell rather
than typing it in every time (it appears from the examples that people are
typing them in every time, which is super tedious; I didn't paste for fear
of doing something damaging, but maybe that would work)?
4) Are the request.id's of the messages dynamic/changing, or are they fixed
for life? I thought I'd delete based on exact request.id without looping
but I was afraid maybe they were changing over time and that this wouldn't
be a good idea. Might be nice to know for the future.
Thanks for the guidance!
Ken
1 year, 11 months

[MM3-users] Re: Attachement processings questions
by Lars Schimmer
On 2020-02-03 20:24, Mark Sapiro wrote:
> On 2/3/20 4:27 AM, Lars Schimmer wrote:
>>
>> In a mailinglist it seems some mails are not forwarded to a member, but
>> is listed in archive in hyperkitty.
>> That mail did include a PDF attachement, but HyperKitty does not list
>> any attachement.
>
>
> There are two issues here. Why wasn't the message delivered to list
> members?, and why is there no attachment in Hyperkitty?
>
> For the first issue, you need to examine mailman.log for the time of the
> post looking for errors and tracebacks. Also, the MTA logs may have
> useful info if the messages were sent but not delivered.
Thank you so far, I maye found the issue:
Uncaught runner exception: 'ascii' codec can't encode character '\xe9'
in position 109: ordinal not in range(128)
Uncaught runner exception: 'ascii' codec can't encode character '\xa0'
in position 37: ordinal not in range(128)
Seems to be the problemm, as it happens the same moment as the
problematic email arrives in exim4:
2020-01-31 03:02:41 1ixLdp-0003Mo-5z => user(a)abc.de R=mailman3_router
T=mailman3_transport H=localhost [127.0.0.1] C="250 Ok"
2020-01-31 03:02:41 1ixLdp-0003Mo-5z Completed
and nothing more. No sign of mailman3 sending out any mail via this list.
Other emails getting to that list will be send out via user-bounces(a)abc.de.
Those mails are in the mailinglist archives, not on hold or anything.
Just the attachement missing.
So, please, howto fix the ascii encoding error in mailman3?
Full trace:
Jan 31 03:02:43 2020 (32591) Uncaught runner exception: 'ascii' codec
can't encode character '\xe9' in position 109: ordinal not in range(128)
Jan 31 03:02:43 2020 (32591) Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/mailman/core/runner.py", line
173, in _one_iteration
self._process_one_file(msg, msgdata)
File "/usr/lib/python3/dist-packages/mailman/core/runner.py", line
266, in _process_one_file
keepqueued = self._dispose(mlist, msg, msgdata)
File "/usr/lib/python3/dist-packages/mailman/runners/pipeline.py",
line 37, in _dispose
process(mlist, msg, msgdata, pipeline)
File "/usr/lib/python3/dist-packages/mailman/core/pipelines.py", line
50, in process
handler.process(mlist, msg, msgdata)
File "/usr/lib/python3/dist-packages/mailman/handlers/to_digest.py",
line 48, in process
mbox.add(msg)
File "/usr/lib/python3.7/mailbox.py", line 603, in add
self._toc[self._next_key] = self._append_message(message)
File "/usr/lib/python3.7/mailbox.py", line 758, in _append_message
offsets = self._install_message(message)
File "/usr/lib/python3.7/mailbox.py", line 830, in _install_message
self._dump_message(message, self._file, self._mangle_from_)
File "/usr/lib/python3.7/mailbox.py", line 215, in _dump_message
gen.flatten(message)
File "/usr/lib/python3.7/email/generator.py", line 116, in flatten
self._write(msg)
File "/usr/lib/python3.7/email/generator.py", line 181, in _write
self._dispatch(msg)
File "/usr/lib/python3.7/email/generator.py", line 214, in _dispatch
meth(msg)
File "/usr/lib/python3.7/email/generator.py", line 432, in _handle_text
super(BytesGenerator,self)._handle_text(msg)
File "/usr/lib/python3.7/email/generator.py", line 249, in _handle_text
self._write_lines(payload)
File "/usr/lib/python3.7/email/generator.py", line 155, in _write_lines
self.write(line)
File "/usr/lib/python3.7/email/generator.py", line 406, in write
self._fp.write(s.encode('ascii', 'surrogateescape'))
UnicodeEncodeError: 'ascii' codec can't encode character '\xe9' in
position 109: ordinal not in range(128)
> For the second, there are many content filtering settings not (yet)
> exposed in Postorius. These include filter_extensions, filter_types,
> pass_extensions and pass_types which control which MIME parts are
> removed. For a newly created Mailman 3 list, these four settings are
> empty, but importing a Mailman 2.1 list will set them according to the
> corresponding MM 2.1 list's settings.
>
>
>> All I found was "convert HTML to plaintext", but does this setting
>> remove attachements?
>
>
> It would only affect HTML parts, not pdfs.
>
>
>> Is there any generel documentation about attachement processing in MM3?
>
>
> <https://mailman.readthedocs.io/en/latest/src/mailman/handlers/docs/filterin…>.
>
>
>
>> I would like this mailinglist to accept mails with attachements, send it
>> to the members and archvie the attachments in HyperKitty, to.
>
>
> You can set Settings -> Alter Messages -> Filter content to No in
> Postorius to not do any content filtering at all. This will override the
> Collapse alternatives and Convert html to plaintext settings and pass
> the message without removing any MIME parts.
>
> But, I think you must have other issues, either with this mail in
> particular or in general as evidenced by the mail not being received by
> list members.
Ok, first fix the ascii encode error for me. Any idea how?
thank you.
MfG,
Lars Schimmer
--
-------------------------------------------------------------
TU Graz, Institut für ComputerGraphik & WissensVisualisierung
Tel: +43 316 873-5405 E-Mail: l.schimmer(a)cgv.tugraz.at
Fax: +43 316 873-5402 PGP-Key-ID: 0x4A9B1723
5 years, 4 months

[MM3-users] Re: integrating mm3 with postfix / lmtp
by Thor Atle Rustad
I will try to get a grip on uid namespaces then...
2017-11-13 10:49 GMT+01:00 Abhilash Raj <maxking(a)asynchronous.in>:
> On Nov 13 2017, at 1:34 am, Thor Atle Rustad <thor.rustad(a)gmail.com>
> wrote:
>
>> 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").
>>
>
> Containers usually run with uid namespace, so it doesn't really matter
> what uid is used outside of container.
>
> Unless, you mount /etc/shadow from host in to the container, which isn't
> really needed for the images.
>
>
>> 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, 6 months

[MM3-users] Re: Errors while importing mm2 list archives
by Odhiambo Washington
On Thu, Dec 8, 2022 at 10:41 PM Mark Sapiro <mark(a)msapiro.net> wrote:
> On 12/8/22 07:23, Odhiambo Washington wrote:
> > MM3-3.3.7, Hyperkitty-1.3.6
> >
> > While importing, I encountered several of this error:
> >
> > <CUT>
> > MySQLdb.OperationalError: (1366, "Incorrect string value:
> > '\\xF0\\x9F\\x98\\x8A, ...' for column 'content' at row 1")
> > The above exception was the direct cause of the following exception:
> ...
> > File
> >
> "/opt/mailman/mm/venv/lib/python3.9/site-packages/django/db/backends/mysql/base.py",
>
>
> That's a 4-byte utf-8 encoding for an emoji. MySQL and MariaDB have to be
> told to accept 4-byte encodings.
>
> In the DATABASES['default'] definition, you need to set `'OPTIONS':
> {'charset': 'utf8mb4'}`
>
I added that:
[database]
class: mailman.database.mysql.MySQLDatabase
url: mysql+pymysql://mailman_user:XXXXXXXXX@localhost
/mailmansuite?charset=utf8mb4&use_unicode=1
> Also, although it doesn't affect this, see
>
> https://docs.mailman3.org/projects/mailman/en/latest/src/mailman/docs/datab…
I read this too. Did not pick much from there.
> You might also need to modify the tables, particularly hyperkitty_email
> with something like
> ```
> ALTER TABLE hyperkitty_email
> DEFAULT CHARACTER SET utf8mb4,
> MODIFY subject varchar(512)
> CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci,
> MODIFY content
> CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;
>
So I removed my list, dropped the database, and proceeded as follows:
create database mailmansuite CHARACTER SET utf8mb4 COLLATE
utf8mb4_0900_ai_ci;
ALTER TABLE hyperkitty_email DEFAULT CHARACTER SET utf8mb4;
ALTER TABLE hyperkitty_email MODIFY subject varchar(512) CHARACTER SET
utf8mb4 COLLATE utf8mb4_unicode_ci;
ALTER TABLE hyperkitty_email MODIFY content longtext CHARACTER SET utf8mb4
COLLATE utf8mb4_unicode_ci;
ALTER TABLE hyperkitty_email MODIFY sender_name varchar(255) CHARACTER SET
utf8mb4 COLLATE utf8mb4_unicode_ci;
ALTER TABLE hyperkitty_email MODIFY in_reply_to varchar(255) CHARACTER SET
utf8mb4 COLLATE utf8mb4_unicode_ci;
I did all those (although looks overzealous) just to be on the safe side. I
have seen people putting emojis in their names.
After that, I did the mailman-web migrate, created the list, imported the
config from MM2 and then proceeded to import the archives.
However, the errors still are there, and several messages were not imported
- I have several "failed to import" warnings.
<CUT>
django.db.utils.OperationalError: (1366, "Incorrect string value:
'\\xF0\\x9F\\x98\\x8A, ...' for column 'content' at row 1")
Message 253d9d44-cc3e-fed1-144b-34da88c52b39(a)emailplus.org failed to
import, skipping *<================== several of these "failed to import"
messages*
Computing thread structure
Synchronizing properties with Mailman
905 emails left to refresh, checked 0
765 emails left to refresh, checked 0
Warming up cache
Traceback (most recent call last):
File "/opt/mailman/mm/venv/bin/django-admin", line 8, in <module>
sys.exit(execute_from_command_line())
File
"/opt/mailman/mm/venv/lib/python3.9/site-packages/django/core/management/__init__.py",
line 446, in execute_from_command_line
utility.execute()
File
"/opt/mailman/mm/venv/lib/python3.9/site-packages/django/core/management/__init__.py",
line 440, in execute
self.fetch_command(subcommand).run_from_argv(self.argv)
File
"/opt/mailman/mm/venv/lib/python3.9/site-packages/django/core/management/base.py",
line 402, in run_from_argv
self.execute(*args, **cmd_options)
File
"/opt/mailman/mm/venv/lib/python3.9/site-packages/django/core/management/base.py",
line 448, in execute
output = self.handle(*args, **options)
File
"/opt/mailman/mm/venv/lib/python3.9/site-packages/hyperkitty/management/commands/hyperkitty_import.py",
line 411, in handle
call_command("hyperkitty_warm_up_cache", list_address)
File
"/opt/mailman/mm/venv/lib/python3.9/site-packages/django/core/management/__init__.py",
line 198, in call_command
return command.execute(*args, **defaults)
File
"/opt/mailman/mm/venv/lib/python3.9/site-packages/django/core/management/base.py",
line 448, in execute
output = self.handle(*args, **options)
File
"/opt/mailman/mm/venv/lib/python3.9/site-packages/hyperkitty/management/commands/hyperkitty_warm_up_cache.py",
line 53, in handle
self.warm_up_mlist(mlist, options)
File
"/opt/mailman/mm/venv/lib/python3.9/site-packages/hyperkitty/management/commands/hyperkitty_warm_up_cache.py",
line 61, in warm_up_mlist
for thread in mlist.recent_threads:
File
"/opt/mailman/mm/venv/lib/python3.9/site-packages/hyperkitty/models/mailinglist.py",
line 162, in recent_threads
return self.cached_values["recent_threads"]()
File
"/opt/mailman/mm/venv/lib/python3.9/site-packages/hyperkitty/models/common.py",
line 58, in __call__
return self.get_or_set(*args, **kwargs)
File
"/opt/mailman/mm/venv/lib/python3.9/site-packages/hyperkitty/models/mailinglist.py",
line 317, in get_or_set
return [Thread.objects.get(pk=pk) for pk in thread_ids]
File
"/opt/mailman/mm/venv/lib/python3.9/site-packages/hyperkitty/models/mailinglist.py",
line 317, in <listcomp>
return [Thread.objects.get(pk=pk) for pk in thread_ids]
File
"/opt/mailman/mm/venv/lib/python3.9/site-packages/django/db/models/manager.py",
line 85, in manager_method
return getattr(self.get_queryset(), name)(*args, **kwargs)
File
"/opt/mailman/mm/venv/lib/python3.9/site-packages/django/db/models/query.py",
line 650, in get
raise self.model.DoesNotExist(
hyperkitty.models.thread.Thread.DoesNotExist: Thread matching query does
not exist.
(venv) [mailman@gw ~/mm]$
It therefore means I have several broken threads in the archives.
I am still willing to try other solutions if they are suggested.
And what do I make of the final error -
*hyperkitty.models.thread.Thread.DoesNotExist:
Thread matching query does not exist*. ??
--
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: Docker Support Sucks
by Brian Carpenter
On 7/21/20 8:55 PM, Mark Sapiro wrote:
> On 7/21/20 5:40 PM, Brian Carpenter wrote:
>
> Abhilash (@maxking) is one person and he has a $DayJob. We're all doing
> the best we can.
Well, I still need support.
> This is not a Docker issue per se. It is a consequence of upgrading
> Mailman core to 3.3.1+ and processing many old, stale, previously
> unprocessed bounces. See
> <https://lists.mailman3.org/archives/list/mailman-users@mailman3.org/thread/…>
I am not worried about the bounce issues at this point. I am just trying
to get a membership list exported for a client.
>
>> So, I want to totally move away from the use of Docker (mainly because I have found it buggy and the support is simply lacking) and install Mailman 3 for this client from source. However I need to get an export of their list members. But of course, I can't. Rest API times out and I don't know how to apply the instructions I was given to fix it and I don't have days to way for one. So please help.
>>
>> I increased the gunicorn workers to 4, hoping that would allow me to do the CSV export. No. So was given these instructions:
>>
>> ###
>> The issues seems to be due to timeout not due to high load. You want to increase the timeout for gunicorn and you can do that by specifying a gunicorn.ini config file:
>>
>> [webservice]
>> configuration: /path/to/gunicorn.cfg
>>
>> and then in the gunicorn.cfg you can add
>>
>> [gunicorn]
>> timeout = 90
>> graceful_timeout = 30
>> ###
>>
>> I applied the above changes to /opt/mailman/core/mailman-extra.cfg and created the gunicorn.cfg file. Restarted the docker container (mailman-core) and no access to Postorius due to no REST api.
>>
>> After restarting docker-mailman, I can't access Postorius due to the following error:
>>
>> ERROR 2020-07-20 20:16:27,351 15 postorius Mailman REST API not available
> Is Mailman core running? If not, whats in core's mailman.log as to why not?
It looks like but no error message in mailman.log. However I noted that
the gunicorn process did not start.
This is with the configuration line enabled in mailman-extra.cfg:
# docker-compose restart mailman-core
Restarting mailman-core ... done
[root@nicu-net docker-mailman]# tail -f
/opt/mailman/core/var/logs/mailman.log
Jul 22 01:25:17 2020 (22) in runner caught SIGTERM. Stopping.
Jul 22 01:25:17 2020 (25) out runner caught SIGTERM. Stopping.
Jul 22 01:25:17 2020 (25) out runner exiting.
Jul 22 01:25:17 2020 (21) command runner exiting.
Jul 22 01:25:17 2020 (22) in runner exiting.
Jul 22 01:25:17 2020 (24) nntp runner caught SIGTERM. Stopping.
Jul 22 01:25:17 2020 (24) nntp runner exiting.
[2020-07-22 01:25:19 +0000] [27] [INFO] Shutting down: Master
Jul 22 01:25:21 2020 (1) Master stopped
Jul 22 01:25:26 2020 (1) Master started
Jul 22 01:25:44 2020 (27) rest runner started.
Jul 22 01:25:44 2020 (26) pipeline runner started.
Jul 22 01:25:44 2020 (20) bounces runner started.
Jul 22 01:25:45 2020 (22) in runner started.
Jul 22 01:25:45 2020 (28) retry runner started.
Jul 22 01:25:46 2020 (29) virgin runner started.
Jul 22 01:25:46 2020 (25) out runner started.
Jul 22 01:25:46 2020 (23) lmtp runner started.
Jul 22 01:25:46 2020 (24) nntp runner started.
Jul 22 01:25:47 2020 (30) digest runner started.
Jul 22 01:25:47 2020 (19) archive runner started.
Jul 22 01:25:47 2020 (21) command runner started.
This is with the configuration line disabled in mailman-extra.cfg:
# docker-compose restart mailman-core
Restarting mailman-core ... done
[root@nicu-net docker-mailman]# tail -f
/opt/mailman/core/var/logs/mailman.log
Jul 22 01:27:49 2020 (1) Master stopped
Jul 22 01:27:53 2020 (1) Master started
Jul 22 01:28:10 2020 (30) digest runner started.
Jul 22 01:28:10 2020 (29) virgin runner started.
Jul 22 01:28:10 2020 (24) nntp runner started.
Jul 22 01:28:10 2020 (25) out runner started.
Jul 22 01:28:10 2020 (22) in runner started.
Jul 22 01:28:11 2020 (28) retry runner started.
Jul 22 01:28:11 2020 (27) rest runner started.
[2020-07-22 01:28:11 +0000] [27] [INFO] Starting gunicorn 19.9.0
[2020-07-22 01:28:11 +0000] [27] [INFO] Listening at:
http://172.19.199.2:8001 (27)
[2020-07-22 01:28:11 +0000] [27] [INFO] Using worker: sync
[2020-07-22 01:28:11 +0000] [32] [INFO] Booting worker with pid: 32
[2020-07-22 01:28:11 +0000] [33] [INFO] Booting worker with pid: 33
[2020-07-22 01:28:11 +0000] [34] [INFO] Booting worker with pid: 34
[2020-07-22 01:28:11 +0000] [35] [INFO] Booting worker with pid: 35
Jul 22 01:28:11 2020 (19) archive runner started.
Jul 22 01:28:11 2020 (21) command runner started.
Jul 22 01:28:12 2020 (23) lmtp runner started.
Jul 22 01:28:12 2020 (20) bounces runner started.
Jul 22 01:28:12 2020 (26) pipeline runner started.
--
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/
4 years, 10 months

[MM3-users] Re: django-allauth failures, but only for some users (independent of browser?)
by Jered Floyd
FYI, The django-allauth author has proposed fixing both of these with an even simpler change, which is now upstream and queued for a future release.
--Jered
--- a/allauth/socialaccount/adapter.py
+++ b/allauth/socialaccount/adapter.py
@@ -228,7 +228,10 @@ class DefaultSocialAccountAdapter(object):
provider_to_apps = {}
# First, populate it with the DB backed apps.
- db_apps = SocialApp.objects.on_site(request)
+ if request:
+ db_apps = SocialApp.objects.on_site(request)
+ else:
+ db_apps = SocialApp.objects.all()
if provider:
db_apps = db_apps.filter(Q(provider=provider) | Q(provider_id=provider))
if client_id:
----- On Dec 7, 2023, at 3:14 PM, Jered Floyd jered(a)convivian.com wrote:
> 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
> _______________________________________________
> 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: Huge performance issue: Mailman doesn't (seem to) receive any mails.
by Henrik Rasmussen
Mark Sapiro wrote:
> This seems to say that the Postfix container can connect to
> 172.19.199.2:8024 and receive the greeting from Mailman's lmtp runner.
> So, why can't Postfix send to 172.19.199.2:8024?
That is why I figured that the problem could be Mailman bloking for more mails, somhow.
> The only log entry you
> postes just says "Sep 18 10:07:47 postfix postfix/qmgr[98]: warning:
> mail for [172.19.199.2]:8024 is using up 7844 of 7844 active queue entries".
> What other log entries relate to attempts to send to 172.19.199.2:8024?
> You may have to go back to when this first started to see them.
Docker deleted it's log when restaring, as the container is deleted and removed, but the starte of the current log says:
```
Sep 18 13:28:57 postfix rsyslogd: [origin software="rsyslogd" swVersion="7.4.7" x-pid="20" x-info="http://www.rsyslog.com"] start
Sep 18 13:29:00 postfix postfix/postfix-script[94]: starting the Postfix mail system
Sep 18 13:29:00 postfix postfix/master[96]: daemon started -- version 2.10.1, configuration /etc/postfix
Sep 18 13:29:02 postfix postfix/smtpd[102]: connect from incoming.gateway.example.com[192.168.111.222]
Sep 18 13:29:04 postfix postfix/smtpd[102]: EFF017E9D65AE: client=incoming.gateway.example.com[192.168.111.222]
Sep 18 13:29:04 postfix postfix/cleanup[106]: EFF017E9D65AE: message-id=<2E40950170CA0A4A8D0F0C0CF1C0630601B8B9F412(a)P1KITMBX03WC02.unicph.domain>
Sep 18 13:29:04 postfix opendkim[19]: EFF017E9D65AE: incoming.gateway.example.com [192.168.111.222] not internal
Sep 18 13:29:04 postfix opendkim[19]: EFF017E9D65AE: not authenticated
Sep 18 13:29:04 postfix postfix/smtpd[102]: disconnect from incoming.gateway.example.com[192.168.111.222]
Sep 18 13:29:18 postfix postfix/qmgr[98]: 0E53F7E9D7D8D: from=<>, size=212010, nrcpt=1 (queue active)
Sep 18 13:29:18 postfix postfix/qmgr[98]: C51DE7E9920B8: from=<>, size=212004, nrcpt=1 (queue active)
Sep 18 13:29:18 postfix postfix/qmgr[98]: 2923A7E99B41F: from=<>, size=212040, nrcpt=1 (queue active)
Sep 18 13:29:18 postfix postfix/qmgr[98]: D0A1E7E981E26: from=<quarantine(a)messaging.microsoft.com>, size=14542, nrcpt=1 (queue active)
Sep 18 13:29:18 postfix postfix/qmgr[98]: 95FA77E9815A5: from=<>, size=211977, nrcpt=1 (queue active)
Sep 18 13:29:18 postfix postfix/qmgr[98]: 208777E993635: from=<sender(a)example.com>, size=9826184, nrcpt=1 (queue active)
Sep 18 13:29:18 postfix postfix/qmgr[98]: 757C27E9BD45C: from=<>, size=211997, nrcpt=1 (queue active)
Sep 18 13:29:18 postfix postfix/qmgr[98]: 738C87E9B94BE: from=<>, size=212141, nrcpt=1 (queue active)
[SLIP]
Sep 18 13:32:24 postfix postfix/anvil[103]: statistics: max cache size 1 at Sep 18 13:29:02
Sep 18 13:43:48 postfix postfix/smtpd[992]: connect from gateway[172.19.199.1]
Sep 18 13:43:48 postfix postfix/smtpd[992]: 9E0D37E9D65AF: client=gateway[172.19.199.1]
Sep 18 13:43:48 postfix postfix/cleanup[996]: 9E0D37E9D65AF: message-id=<3e08121bcdf5b0ebeb779a26ab2fe6ef(a)mailing.einnews.com>
Sep 18 13:43:48 postfix opendkim[19]: 9E0D37E9D65AF: DKIM-Signature field added (s=default, d=sendergateway.example.com)
Sep 18 13:43:48 postfix postfix/smtpd[992]: disconnect from gateway[172.19.199.1]
Sep 18 13:43:48 postfix postfix/qmgr[98]: 9E0D37E9D65AF: from=<sender(a)example.com>, size=59393, nrcpt=1 (queue active)
Sep 18 13:43:48 postfix postfix/qmgr[98]: warning: mail for [172.19.199.2]:8024 is using up 7863 of 7863 active queue entries
Sep 18 13:43:48 postfix postfix/qmgr[98]: warning: you may need to reduce lmtp connect and helo timeouts
Sep 18 13:43:48 postfix postfix/qmgr[98]: warning: so that Postfix quickly skips unavailable hosts
Sep 18 13:43:48 postfix postfix/qmgr[98]: warning: you may need to increase the main.cf minimal_backoff_time and maximal_backoff_time
Sep 18 13:43:48 postfix postfix/qmgr[98]: warning: so that Postfix wastes less time on undeliverable mail
Sep 18 13:43:48 postfix postfix/qmgr[98]: warning: you may need to increase the master.cf lmtp process limit
Sep 18 13:43:48 postfix postfix/qmgr[98]: warning: please avoid flushing the whole queue when you have
Sep 18 13:43:48 postfix postfix/qmgr[98]: warning: lots of deferred mail, that is bad for performance
Sep 18 13:43:48 postfix postfix/qmgr[98]: warning: to turn off these warnings specify: qmgr_clog_warn_time = 0
```
We see the queueing in Postfix as Mailman is not receiving and that this is why Postfix is using up all it's active queue entries.
However, suddenly this morning, everything came alive all by itself. The question left is: What held the flow. If we don't know what held it, it may happen again, so I would really like some help to understand the problem.
```
Sep 20 07:05:23 postfix opendkim[19]: 23AED7E98F748: incoming.gateway.example.com [192.168.111.222] not internal
Sep 20 07:05:23 postfix opendkim[19]: 23AED7E98F748: not authenticated
Sep 20 07:05:23 postfix postfix/smtpd[20713]: disconnect from incoming.gateway.example.com[192.168.111.222]
Sep 20 07:05:23 postfix postfix/qmgr[16738]: 23AED7E98F748: from=<someone(a)foo.bar>, size=4379, nrcpt=1 (queue active)
Sep 20 07:05:23 postfix postfix/qmgr[16738]: warning: mail for [172.19.199.2]:8024 is using up 5363 of 5364 active queue entries
Sep 20 07:05:23 postfix postfix/qmgr[16738]: warning: you may need to increase the main.cf lmtp_destination_concurrency_limit from 20
Sep 20 07:05:23 postfix postfix/qmgr[16738]: warning: please avoid flushing the whole queue when you have
Sep 20 07:05:23 postfix postfix/qmgr[16738]: warning: lots of deferred mail, that is bad for performance
Sep 20 07:05:23 postfix postfix/qmgr[16738]: warning: to turn off these warnings specify: qmgr_clog_warn_time = 0
Sep 20 07:05:23 postfix postfix/lmtp[20393]: B64F97E9D0BF4: to=<LISTNAME-bounces(a)lists.example.com>, relay=172.19.199.2[172.19.199.2]:8024, conn_use=4, delay=663077, delays=659443/3624/1/8.1, dsn=2.0.0, status=sent (250 Ok)
Sep 20 07:05:23 postfix postfix/qmgr[16738]: B64F97E9D0BF4: removed
```
/ Henrik Rasmussen
5 years, 8 months

[MM3-users] Re: [Mailman-Users] Mailman 3 on Ubuntu 18.04
by Odhiambo Washington
On Sun, 9 Dec 2018 at 22:37, Mark Sapiro <mark(a)msapiro.net> wrote:
> On 12/9/18 10:14 AM, Odhiambo Washington wrote:
> >
> > In my quest to run Mailman3, I obtained a VM running Ubuntu 18.04 and
> > started on getting to run Mailman3.
> > I found this link -> https://github.com/iomarmochtar/mailman3_ei
> > It has instructions which looked fairly simple to get Mailman3 installed.
> > However, I did encounter some hitches since the script is not meant for
> > Ubuntu.
>
>
> First, a more appropriate list for Mailman 3 is
> mailman-users(a)mailman3.org
> <https://lists.mailman3.org/mailman3/lists/mailman-users@mailman3.org/>.
>
I am shifting to that list, after this.
>
> Also, we find it very difficult to address issues arising from third
> party packages and how-tos. See <https://wiki.list.org/x/12812344>.
>
> And, there is a Mailman 3 package for Debian/Ubuntu
>
> apt install mailman3-full
>
In all my searching, I never found this in any documentation. I must have
been searching in the wild, or my FreeBSD-mindedness got me stuck to
containers and VENVs.
> > With a few runs and observing the logs and modifying the script at every
> > step it encountered and error, I finally managed to install Mailman3. It
> > seems this is what you guys call a virtual environment in the Linux
> world?
> > :-)
>
>
> I think the virtual environment in this case is a Python thing, not a
> Linux thing.
>
I agree with you on that.
> <snip>
>
>
> Much of what I snipped is specific to
> <https://github.com/iomarmochtar/mailman3_ei>, the details of which I'm
> not interested in learning.
>
That is fine. I have put it aside for now.
>
>
> >>From this point now is where I need help - serious help in smoothening
> > things up and getting to understand these venv stuff!
> >
> > So I did run 'service mailman3 start' but this seems to be waiting for
> too
> > long to drop me back into the CLI.
> > I also run 'systemctl start supervisord' and that seems to work. What I
> am
> > not sure is whether 'systemctl stop supervisord' actually does what it is
> > expected to do because after I execute it, I still see processes running
> > that I think are related.
> >
> > So far, I have been able to access the webUI on my VM using
> > https://N.N.N.N:9090
> > I created a domain.
> > But when I create a test list, I get an error - and I do not have a clue
> > which logfile would have the error details - nginx or mailman... (I am
> 100%
> > new to nginx).
>
>
> The nginx logs generally aren't too useful. Both Mailman core and Django
> write logs. Core's log is probably in var/log/mailman.log where is
> defined in mailman.cfg as var_dir. Django's log is defined in Django's
> settings in the LOGGING setting.
>
Which file contains Django's settings?
> > So now, I am stuck at:
> > 1. Creating the mailing list
> > 2. Getting to know whether the archiver is installed and running
> > 3. Knowing is there are cron jobs to be running (Mailman2 type of
> thinking!)
>
>
> See
> <http://docs.mailman3.org/en/latest/config-core.html#configuring-cron-jobs
> >
> and
> <
> http://docs.mailman3.org/en/latest/config-web.html#scheduled-tasks-required
> >
>
Great to see that. I'll read and see if I make heads or tails of the
writeup.
> > Ultimately I need to figure out:
> > 1. How the mailman queue runners are started and stopped
>
> mailman start
>
Why not systemctl mailman start?? Just wondering, as that is what I am
seeing is common in Ubuntu.
Does this make the components start after a reboot?
> > 2. Migrate s few lists from Mailman2 to this Mailman3
>
> mailman import21
> <django management> hyperkitty_import
>
Please show me where that is documented. I have to pull my lists from an
old machine to this new one.
> > 3. Mailman3 should use MySQL storage and Exim4 as the MTA (I have
> > configured these bits in mailman.cfg)
>
>
> You also need to configure MySQL in Django. See the DATABASES setting in
> the Django settings.
>
So, when you talk about Django settings, you are referring to mailman.cfg
file??? :-)
I have spent all my weekend till now, trying to figure all this out. Life
seems a little easier with mm2.x ....
Thank you.
--
Best regards,
Odhiambo WASHINGTON,
Nairobi,KE
+254 7 3200 0004/+254 7 2274 3223
"Oh, the cruft."
6 years, 5 months

[MM3-users] Re: Message is received but is not sent out. Another, similar message, is processed fine.
by Allan Hansen
Thank you, Mark.
I see this in mailman.log. I had looked there for her email address, but it does not appear, so I moved on to the smtp.log.
In
Jun 26 17:18:11 2023 (1243315) ACCEPT: ^M
<CH3PR12MB82593801A1DF2E329E977046BE27A(a)CH3PR12MB8259.namprd12.prod.outlook.com>
Jun 26 17:18:11 2023 (1243319) Uncaught runner exception: unknown encoding: iso-8859-8-i
Jun 26 17:18:11 2023 (1243319) Traceback (most recent call last):
File "/opt/mailman/mm/venv/lib/python3.9/site-packages/mailman/core/runner.py", line 179, in _one_iteration
self._process_one_file(msg, msgdata)
File "/opt/mailman/mm/venv/lib/python3.9/site-packages/mailman/core/runner.py", line 272, in _process_one_file
keepqueued = self._dispose(mlist, msg, msgdata)
File "/opt/mailman/mm/venv/lib/python3.9/site-packages/mailman/runners/pipeline.py", line 37, in _dispose
process(mlist, msg, msgdata, pipeline)
File "/opt/mailman/mm/venv/lib/python3.9/site-packages/mailman/core/pipelines.py", line 53, in process
handler.process(mlist, msg, msgdata)
File "/opt/mailman/mm/venv/lib/python3.9/site-packages/mailman/handlers/mime_delete.py", line 382, in process
process(mlist, msg, msgdata)
File "/opt/mailman/mm/venv/lib/python3.9/site-packages/mailman/handlers/mime_delete.py", line 151, in process
reset_payload(msg, firstalt)
File "/opt/mailman/mm/venv/lib/python3.9/site-packages/mailman/handlers/mime_delete.py", line 202, in reset_payload
msg.set_payload(subpart.get_payload(decode=True).decode(
LookupError: unknown encoding: iso-8859-8-i
Jun 26 17:18:11 2023 (1243319) SHUNTING: 1687825091.8457294+478565324778f2eb6f0fecaeccbd29596edaef53
I also see this in queue/shunt:
mailman@list:~/var/queue/shunt$ ls -ltr
total 88
-rw-rw---- 1 mailman mailman 7168 Feb 17 23:03 1676703781.903885+fdcba88c680f50a0799c672cd0abe82e4bfe19b3.pck
-rw-rw---- 1 mailman mailman 19821 Apr 2 07:08 1680444501.0831451+e110b8c5c20ba3f87c1cea1c5f38e74a6cf8f1c5.pck
-rw-rw---- 1 mailman mailman 19489 Jun 18 11:52 1687114364.41209+1684717da96ff76d1ce773a0cf39c5f8b63e9078.pck
-rw-rw---- 1 mailman mailman 20274 Jun 18 19:01 1687140067.64057+7f77c1ebca490831f58ef9cfde06109081a4e7d6.pck
-rw-rw---- 1 mailman mailman 20085 Jun 26 17:18 1687825091.8457294+478565324778f2eb6f0fecaeccbd29596edaef53.pck
The three last entries coincide with the captured messages.
Finally, in the captured message source (the last which was Cc'd to me) I do see this:
Content-Type: text/plain; charset="iso-8859-8-i"
Which matches the complaint in the mailman log.
In the message that did get accepted, I see this:
Content-Type: text/plain; charset="utf-8"
Another difference:
The posted message shows
Content-Transfer-Encoding: base64
The shunted message shows
Content-Transfer-Encoding: quoted-printable
It appears that the two messages are, indeed, different, despite the similar looks when rendered.
My question thus changes to:
a. Should she be doing something special when sending to the lists?
b. If not, is my setup in need of change?
Yours,
Allan
On 6/26/23, 20:44, "Mark Sapiro" <mark(a)msapiro.net <mailto:mark@msapiro.net>> wrote:
On 6/26/23 8:09 PM, Allan Hansen wrote:
> Hi all,
>
> One of my subscribers is trying to send a message to a list, but it is not being posted.
> The smtp.log shows that her first message was posted, but a second message (with 2 retries) was not:
>
> mailman@list:~/logs$ grep herName smtp.log
> Jun 18 11:22:05 2023 (1243316) ('127.0.0.1', 56686) >> b'MAIL FROM:<herName(a)hotmail.com <mailto:herName@hotmail.com>> SIZE=40109'
> Jun 18 11:22:05 2023 (1243316) ('127.0.0.1', 56686) sender: herName(a)hotmail.com <mailto:herName@hotmail.com>
> Jun 18 11:25:01 2023 (1243318) <CH3PR12MB82593510B90D8F05177C606BBE5EA(a)CH3PR12MB8259.namprd12.prod.outlook.com <mailto:CH3PR12MB82593510B90D8F05177C606BBE5EA@CH3PR12MB8259.namprd12.prod.outlook.com>> post to theList(a)domain.tlc <mailto:theList@domain.tlc> from herName(a)hotmail.com <mailto:herName@hotmail.com>, 40061 bytes
> Jun 18 11:52:42 2023 (1243316) ('127.0.0.1', 48448) >> b'MAIL FROM:<herName(a)hotmail.com <mailto:herName@hotmail.com>> SIZE=18343'
> Jun 18 11:52:42 2023 (1243316) ('127.0.0.1', 48448) sender: herName(a)hotmail.com <mailto:herName@hotmail.com>
> Jun 18 19:01:04 2023 (1243316) ('127.0.0.1', 59550) >> b'MAIL FROM:<herName(a)hotmail.com <mailto:herName@hotmail.com>> SIZE=19123'
> Jun 18 19:01:04 2023 (1243316) ('127.0.0.1', 59550) sender: herName(a)hotmail.com <mailto:herName@hotmail.com>
> Jun 26 17:18:11 2023 (1243316) ('127.0.0.1', 44732) >> b'MAIL FROM:<herName(a)hotmail.com <mailto:herName@hotmail.com>> SIZE=18930'
> Jun 26 17:18:11 2023 (1243316) ('127.0.0.1', 44732) sender: herName(a)hotmail.com <mailto:herName@hotmail.com>
>
> At the second retry she copied me and I saw nothing untowards in her message.
> She's not getting any error return messages and her subscription is OK.
> Both messages were multipart/alternative and both contained Hebrew text.
>
> I told her I'd look at this, but I'm at a loss.
smtp.log is not very useful for diagnosing things like this. It only
says a message was received, not why it didn't result in a post from the
list as in the first case. What's in mailman.log with those timestamps?
--
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/F4K7HYUYSWEKF6LT35UCT3KBJX6GHY4I/
This message sent to hansen(a)rc.org <mailto:hansen@rc.org>
1 year, 11 months

[MM3-users] Re: old usernames appearing in mailman.log
by Ken Alker
--On Monday, June 26, 2023 5:03 PM -0700 Mark Sapiro <mark(a)msapiro.net>
wrote:
> On 6/25/23 10:57 PM, Ken Alker wrote:
>>
>> 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).
>
>
> Each time there is a new post, it retries all the messages in the spool/
> directory.
>
>
>> 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.
>
>
> Are new messages being archived OK. If so, that is a real mystery. It
> says mailman-hyperkitty can talk to hyperkitty and archive new messages,
> but it can't talk to hyperkitty when attempting to process a queued
> message.
Ahhh! I had convinced myself that new messages were being archived, but
now that you ask, they ARE NOT. I may have said they were at some point,
and I apologize if I did. Now I feel less confused.
It appears that archiving stopped when I did the migration from "Debian
package layout" to "source layout" and upgraded to V3.3.8. I'll bet I
munged a config file or two. I was struggling with what to keep from
Debian layout and what to bring over from the source install instructions
and I haven't gone back through to clean them up. I had previously figured
it could not be a configuration issue since some messages were making it
into the archive and some were not, but now that I see NONE are making it,
this makes the problem less daunting.
>> 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:
>
> I just went to that URL and got a 404. This is a serious problem.
> https://lists.netlojix.com/hyperkitty/api/ also returns a 404. It should
> return some documentation of the API.
>
> https://lists.netlojix.com/archives/api/ does work and returns the
> expected information.
>
> Your urls.py file probably contains in its urlpatterns list
> ```
> re_path(r'^mailman3/', include('postorius.urls')),
> re_path(r'^archives/', include('hyperkitty.urls')),
> ```
> The simplest fix is to add
> ```
> re_path(r'^postorius/', include('postorius.urls')),
> re_path(r'^hyperkitty/', include('hyperkitty.urls')),
> ```
> to that list.
I see many ursl.py files all over the system, but none that appear to be
where I'd expect them to be for processing by any executables. Is this a
file I should have copied over and edited, or created from scratch and
somehow missed? I don't see anything about it in the instructions at
<https://docs.mailman3.org/en/latest/install/virtualenv.html> (although I
do see a post from last July from someone stating it got missed in the
instructions back then).
> Another way to fix this is in your mailman-hyperkitty.cfg, you have
> ```
> base_url: https://lists.netlojix.com/hyperkitty
> ```
> Change that to
> ```
> base_url: https://lists.netlojix.com/archives
> ```
Done, and restarted both services, but I'm not seeing a difference when I
go to <https://lists.netlojix.com/hyperkitty/api/> (I was getting a "Page
not found", and still get that).
> but it wouldn't hurt to add the `^postorius/` and `^hyperkitty/` patterns
> to urls.py anyway.
1 year, 11 months

[MM3-users] Re: Postorius no connection to REST API
by Richard Rosner
Mark Sapiro wrote:
> > You are in a better position to answer that than am I.
> What does sudo netstat -lntp show?
A lot. But since most of that isn't relevant here:
Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name
tcp 0 0 0.0.0.0:465 0.0.0.0:* LISTEN 20241/master
tcp 0 0 127.0.0.1:8024 0.0.0.0:* LISTEN 14076/python3
tcp 0 0 0.0.0.0:25 0.0.0.0:* LISTEN 20241/master
tcp 0 0 127.0.0.1:8001 0.0.0.0:* LISTEN 14080/python3
tcp 0 0 0.0.0.0:587 0.0.0.0:* LISTEN 20241/master
tcp6 0 0 :::80 :::* LISTEN 13882/apache2
tcp6 0 0 :::465 :::* LISTEN 20241/master
tcp6 0 0 :::25 :::* LISTEN 20241/master
tcp6 0 0 :::443 :::* LISTEN 13882/apache2
tcp6 0 0 :::587 :::* LISTEN 20241/master
> What does ps -fwwa|grep rest show?
root 15055 14843 0 12:58 pts/1 00:00:00 grep rest
So whatever it's supposed to find, it's not there
> > mailman3-web.service must also run as list.
I changed that. It didn't like it.
systemctl status mailman3-web.service
● mailman3-web.service - Mailman3-web uWSGI service
Loaded: loaded (/lib/systemd/system/mailman3-web.service; enabled; vendor preset: enabled)
Active: failed (Result: exit-code) since Wed 2021-08-11 13:05:39 CEST; 32s ago
Docs: file:///usr/share/doc/mailman3-web/README.rst
Process: 15570 ExecStart=/usr/bin/uwsgi --plugin python3 --ini /etc/mailman3/uwsgi.ini (code=exited, status=1/FAILURE)
Main PID: 15570 (code=exited, status=1/FAILURE)
Status: "initializing uWSGI"
Aug 11 13:05:39 mail systemd[1]: Starting Mailman3-web uWSGI service...
Aug 11 13:05:39 mail systemd[1]: mailman3-web.service: Main process exited, code=exited, status=1/FAILURE
Aug 11 13:05:39 mail systemd[1]: mailman3-web.service: Failed with result 'exit-code'.
Aug 11 13:05:39 mail systemd[1]: Failed to start Mailman3-web uWSGI service.
Aug 11 13:05:39 mail systemd[1]: mailman3-web.service: Service RestartSec=100ms expired, scheduling restart.
Aug 11 13:05:39 mail systemd[1]: mailman3-web.service: Scheduled restart job, restart counter is at 5.
Aug 11 13:05:39 mail systemd[1]: Stopped Mailman3-web uWSGI service.
Aug 11 13:05:39 mail systemd[1]: mailman3-web.service: Start request repeated too quickly.
Aug 11 13:05:39 mail systemd[1]: mailman3-web.service: Failed with result 'exit-code'.
Aug 11 13:05:39 mail systemd[1]: Failed to start Mailman3-web uWSGI service.
> > So, what do you have in your apache config for proxying to uwsgi and
> what's your uwsgi configuration.
lists-ssl.conf:
<VirtualHost *:443>
ServerAdmin admin(a)domain.de
ServerName lists.domain.de
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:8001/"
</IfModule>
# SSL Engine Switch:
# Enable/Disable SSL for this virtual host.
SSLEngine on
SSLCertificateFile /etc/ssl/certs/lists.domain.de.cert.pem
SSLCertificateKeyFile /etc/ssl/private/lists.domain.de.private.pem
SSLCertificateChainFile /etc/ssl/certs/dfnca.pem
SSLCACertificateFile /etc/ssl/certs/rwthcert.pem
SSLProtocol all -SSLv3 -TLSv1 -TLSv1.1
Protocols h2 http/1.1
SSLCipherSuite ECDHE-ECDSA-CHACHA20-POLY1305:ECDHE-RSA-CHACHA20-POLY1305:ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:DHE-RSA-AES256-GCM-SHA384:DHE-RSA-AES128-GCM-SHA256
SSLHonorCipherOrder off
#RewriteEngine on
#RewriteRule ^/$ https://lists.domain.de/listinfo
Header always set Strict-Transport-Security "max-age=15768000; includeSubDomains; preload"
Header always set X-Frame-Options: "SAMEORIGIN"
Header always set X-Xss-Protection "1; mode=block"
Header always set X-Content-Type-Options "nosniff"
Header always set Content-Security-Policy "default-src 'self' *.domain.de; script-src 'self' *.domain.de; connect-src 'self' *.domain.de; img-src 'self' *.domain.de; style-src 'self' 'unsafe-inline' *.domain.de; object-src 'self' *.domain.de; frame-src 'self' *.domain.de;"
Header always set Referrer-Policy "no-referrer-when-downgrade"
</VirtualHost>
<VirtualHost *:80>
RewriteEngine On
RewriteRule ^(.*)$ https://%{HTTP_HOST}$1 [R=301,L]
</VirtualHost>
I guess with uwsgi config you mean the /etc/mailman3/uwsgi.ini file?
[uwsgi]
# Port on which uwsgi will be listening.
uwsgi-socket = /run/mailman3-web/uwsgi.sock
#Enable threading for python
enable-threads = true
# Move to the directory wher the django files are.
chdir = /usr/share/mailman3-web
# Use the wsgi file provided with the django project.
wsgi-file = wsgi.py
# Setup default number of processes and threads per process.
master = true
process = 2
threads = 2
# Drop privielges and don't run as root.
uid = www-data
gid = www-data
plugins = python3
# Setup the django_q related worker processes.
attach-daemon = python3 manage.py qcluster
# Setup hyperkitty's cron jobs.
#unique-cron = -1 -1 -1 -1 -1 ./manage.py runjobs minutely
#unique-cron = -15 -1 -1 -1 -1 ./manage.py runjobs quarter_hourly
#unique-cron = 0 -1 -1 -1 -1 ./manage.py runjobs hourly
#unique-cron = 0 0 -1 -1 -1 ./manage.py runjobs daily
#unique-cron = 0 0 1 -1 -1 ./manage.py runjobs monthly
#unique-cron = 0 0 -1 -1 0 ./manage.py runjobs weekly
#unique-cron = 0 0 1 1 -1 ./manage.py runjobs yearly
# Setup the request log.
#req-logger = file:/var/log/mailman3/web/mailman-web.log
# Log cron seperately.
#logger = cron file:/var/log/mailman3/web/mailman-web-cron.log
#log-route = cron uwsgi-cron
# Log qcluster commands seperately.
#logger = qcluster file:/var/log/mailman3/web/mailman-web-qcluster.log
#log-route = qcluster uwsgi-daemons
# Last log and it logs the rest of the stuff.
#logger = file:/var/log/mailman3/web/mailman-web-error.log
logto = /var/log/mailman3/web/mailman-web.log
3 years, 9 months

[MM3-users] Re: LTMP to Postfix problem
by Brian Carpenter
On 6/18/20 7:36 PM, Mark Sapiro wrote:
> Check your system logs to see if there's anything about the OS killing
> the process. Also check the Postfix log for deliveries to mailman just
> before it died. Just stabbing in the dark, but maybe some huge message
> caused it to grow beyond some memory limit and get killed by the OS.
I am replying off list at this point. It is definitely a OOM issue. Here
are the log entries right before ltmp crashed:
Jun 18 00:00:12 mm4 kernel: [19548549.158382] postgres invoked
oom-killer: gfp_mask=0x6200ca(GFP_HIGHUSER_MOVABLE), nodemask=(null),
order=0, oom_score_adj=0
Jun 18 00:00:12 mm4 kernel: [19548549.160719] postgres cpuset=/
mems_allowed=0
Jun 18 00:00:12 mm4 kernel: [19548549.161524] CPU: 0 PID: 7243 Comm:
postgres Not tainted 4.19.0-6-amd64 #1 Debian 4.19.67-2
Jun 18 00:00:12 mm4 kernel: [19548549.163047] Hardware name: QEMU
Standard PC (Q35 + ICH9, 2009), BIOS
rel-1.12.0-0-ga698c8995f-prebuilt.qemu.org 04/01/2014
Jun 18 00:00:12 mm4 kernel: [19548549.164885] Call Trace:
Jun 18 00:00:12 mm4 kernel: [19548549.165402] dump_stack+0x5c/0x80
Jun 18 00:00:12 mm4 kernel: [19548549.166097] dump_header+0x6b/0x283
Jun 18 00:00:12 mm4 kernel: [19548549.167019] ?
do_try_to_free_pages+0x2ec/0x370
Jun 18 00:00:12 mm4 kernel: [19548549.167864]
oom_kill_process.cold.30+0xb/0x1cf
Jun 18 00:00:12 mm4 kernel: [19548549.168760] ? oom_badness+0x23/0x140
Jun 18 00:00:12 mm4 kernel: [19548549.169534] out_of_memory+0x1a5/0x430
Jun 18 00:00:12 mm4 kernel: [19548549.170174]
__alloc_pages_slowpath+0xbd8/0xcb0
Jun 18 00:00:12 mm4 kernel: [19548549.171060]
__alloc_pages_nodemask+0x28b/0x2b0
Jun 18 00:00:12 mm4 kernel: [19548549.171973] filemap_fault+0x3bd/0x780
Jun 18 00:00:12 mm4 kernel: [19548549.172643] ? alloc_set_pte+0xf2/0x560
Jun 18 00:00:12 mm4 kernel: [19548549.173369] ?
filemap_map_pages+0x1ed/0x3a0
Jun 18 00:00:12 mm4 kernel: [19548549.174404]
ext4_filemap_fault+0x2c/0x40 [ext4]
Jun 18 00:00:12 mm4 kernel: [19548549.175259] __do_fault+0x36/0x130
Jun 18 00:00:12 mm4 kernel: [19548549.175930] __handle_mm_fault+0xe6c/0x1270
Jun 18 00:00:12 mm4 kernel: [19548549.176765] handle_mm_fault+0xd6/0x200
Jun 18 00:00:12 mm4 kernel: [19548549.177644] __do_page_fault+0x249/0x4f0
Jun 18 00:00:12 mm4 kernel: [19548549.178407] ? async_page_fault+0x8/0x30
Jun 18 00:00:12 mm4 kernel: [19548549.179156] async_page_fault+0x1e/0x30
Jun 18 00:00:12 mm4 kernel: [19548549.179915] RIP: 0033:0x55d875a3fe10
Jun 18 00:00:12 mm4 kernel: [19548549.180569] Code: Bad RIP value.
Jun 18 00:00:12 mm4 kernel: [19548549.181181] RSP: 002b:00007ffcad32f248
EFLAGS: 00010206
Jun 18 00:00:12 mm4 kernel: [19548549.182132] RAX: 000055d877d512b0 RBX:
000055d877d60b93 RCX: 00007ffcad32f2c0
Jun 18 00:00:12 mm4 kernel: [19548549.183365] RDX: 0000000000000005 RSI:
000055d877d60b93 RDI: 000055d877d512b0
Jun 18 00:00:12 mm4 kernel: [19548549.184712] RBP: 00007ffcad32f270 R08:
0000000000000001 R09: 00007ffcad32f388
Jun 18 00:00:12 mm4 kernel: [19548549.186338] R10: 00007f2585002d40 R11:
0000000000000000 R12: 0000000000000005
Jun 18 00:00:12 mm4 kernel: [19548549.187583] R13: 000055d877d4b3a0 R14:
00007f2581ad05b8 R15: 0000000000000000
Jun 18 00:00:12 mm4 kernel: [19548549.188952] Mem-Info:
Jun 18 00:00:12 mm4 kernel: [19548549.189468] active_anon:197899
inactive_anon:206498 isolated_anon:0
Jun 18 00:00:12 mm4 kernel: [19548549.189468] active_file:253
inactive_file:278 isolated_file:23
Jun 18 00:00:12 mm4 kernel: [19548549.189468] unevictable:0 dirty:0
writeback:0 unstable:0
Jun 18 00:00:12 mm4 kernel: [19548549.189468] slab_reclaimable:21867
slab_unreclaimable:55017
Jun 18 00:00:12 mm4 kernel: [19548549.189468] mapped:17008 shmem:24450
pagetables:4890 bounce:0
Jun 18 00:00:12 mm4 kernel: [19548549.189468] free:13184 free_pcp:340
free_cma:0
Jun 18 00:00:12 mm4 kernel: [19548549.195739] Node 0
active_anon:791596kB inactive_anon:825992kB active_file:1012kB
inactive_file:1112kB unevictable:0kB isolated(anon):0kB
isolated(file):92kB mapped:68032kB dirty$
Jun 18 00:00:12 mm4 kernel: [19548549.200559] Node 0 DMA free:8152kB
min:352kB low:440kB high:528kB active_anon:1056kB inactive_anon:5048kB
active_file:0kB inactive_file:0kB unevictable:0kB writepending:0kB prese$
Jun 18 00:00:12 mm4 kernel: [19548549.204993] lowmem_reserve[]: 0 1950
1950 1950 1950
Jun 18 00:00:12 mm4 kernel: [19548549.205877] Node 0 DMA32 free:44584kB
min:44700kB low:55872kB high:67044kB active_anon:790540kB
inactive_anon:820944kB active_file:1012kB inactive_file:1112kB
unevictable:0kB wri$
Jun 18 00:00:12 mm4 kernel: [19548549.211109] lowmem_reserve[]: 0 0 0 0 0
Jun 18 00:00:12 mm4 kernel: [19548549.211826] Node 0 DMA: 8*4kB (UE)
31*8kB (UME) 20*16kB (UME) 22*32kB (UME) 13*64kB (UME) 5*128kB (UME)
5*256kB (UM) 4*512kB (UM) 2*1024kB (UM) 0*2048kB 0*4096kB = 8152kB
Jun 18 00:00:12 mm4 kernel: [19548549.214414] Node 0 DMA32: 378*4kB
(UMEH) 472*8kB (UEH) 412*16kB (UEH) 196*32kB (UMEH) 63*64kB (UMEH)
63*128kB (UE) 16*256kB (UE) 4*512kB (ME) 0*1024kB 2*2048kB (M) 1*4096kB
(M) =$
Jun 18 00:00:12 mm4 kernel: [19548549.217336] Node 0 hugepages_total=0
hugepages_free=0 hugepages_surp=0 hugepages_size=1048576kB
Jun 18 00:00:12 mm4 kernel: [19548549.218937] Node 0 hugepages_total=0
hugepages_free=0 hugepages_surp=0 hugepages_size=2048kB
Jun 18 00:00:12 mm4 kernel: [19548549.220513] 39729 total pagecache pages
Jun 18 00:00:12 mm4 kernel: [19548549.221286] 14715 pages in swap cache
Jun 18 00:00:12 mm4 kernel: [19548549.222022] Swap cache stats: add
10809560, delete 10794845, find 18524127383/18527544787
Jun 18 00:00:12 mm4 kernel: [19548549.223482] Free swap = 0kB
Jun 18 00:00:12 mm4 kernel: [19548549.224081] Total swap = 524284kB
Jun 18 00:00:12 mm4 kernel: [19548549.224712] 524154 pages RAM
Jun 18 00:00:12 mm4 kernel: [19548549.225222] 0 pages HighMem/MovableOnly
Jun 18 00:00:12 mm4 kernel: [19548549.225894] 13385 pages reserved
Then there was this little bit of info:
Jun 18 00:00:12 mm4 kernel: [19548549.442555] Out of memory: Kill
process 29676 (python3) score 37 or sacrifice child
Jun 18 00:00:12 mm4 kernel: [19548549.444508] Killed process 29676
(python3) total-vm:192224kB, anon-rss:93084kB, file-rss:0kB, shmem-rss:0kB
Jun 18 00:00:12 mm4 kernel: [19548549.464907] oom_reaper: reaped process
29676 (python3), now anon-rss:0kB, file-rss:0kB, shmem-rss:0kB
I suspect the above process was ltmp.
So the server has 2 gig of ram with about a dozen MM3 lists on it. Is
this an issue with tuning performance of the Postgresql server or do I
need to add more memory. I am curious how much ram your server is
running and if you had run into any OOM of problems.
If you want me to post this to the list, I will.
--
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/
4 years, 11 months

[MM3-users] Re: search this list searches more then just this list
by Marco van Tol
Op 26 jan 2024, om 22:55 heeft Mark Sapiro <mark(a)msapiro.net> het volgende geschreven:
> On 1/26/24 02:44, Marco van Tol wrote:
>> Op 25 jan 2024, om 14:16 heeft Marco van Tol <mvantol(a)ripe.net> het volgende geschreven:
>>>
>>> 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!
>
> The message above with the attached "full error" never got to the list. What is the error report?
Hm, I see. Not sure why. The reply I got from mail.mailman3.org <http://mail.mailman3.org/> at 2024-01-25 13:16:25.486 UTC was:
"250 2.0.0 Ok: 12772 bytes queued as 55AFD105C02”
I’m pasting it at the bottom of this email. Sorry it didn’t come through.
>> 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:
>
> That's only part of it. You need
>
> hole = sha224(hole).hexdigest().encode('utf8')
I ended up changing it to this, which fixed that bit, and led to the next issue. :)
>> text = text[:match.start()] + hole + text[match.end():]
>> TypeError: can't concat str to bytes
>> The ‘hash’ part of that function needs some debugging.
>
>
> Yes, presumably because no one sets `XAPIAN_LONG_TERM_METHOD=hash` in the environment. Do you have a reason for this?
I wanted to check and see if I could avoid the “Term too long (>245)" issue this way, but I haven’t gotten to the point where xapian is successful.
Right now I’m back at the original issue as I see no other solution than to go back to whoosh.
Thanks!
Marco van Tol
Paste:
----
Indexing 194620 emails
[ERROR/MainProcess] Failed indexing 156001 - 157000 (retry 5/5): Term too long (> 245): XSUBJECThttp://www.google.com/url?q=%68%74%74%70%73%3a%2f%2f%68%64%72%65%64… (pid 32): Term too long (> 245): XSUBJECThttp://www.google.com/url?q=%68%74%74%70%73%3a%2f%2f%68%64%72%65%64…
Traceback (most recent call last):
File "/usr/lib/python3.11/site-packages/haystack/management/commands/update_index.py", line 119, in do_update
backend.update(index, current_qs, commit=commit)
File "/usr/lib/python3.11/site-packages/xapian_backend.py", line 98, in wrapper
func(self, *args, **kwargs)
File "/usr/lib/python3.11/site-packages/xapian_backend.py", line 505, in update
database.replace_document(document_id, document)
xapian.InvalidArgumentError: Term too long (> 245): XSUBJECThttp://www.google.com/url?q=%68%74%74%70%73%3a%2f%2f%68%64%72%65%64…
[ERROR/MainProcess] Error updating hyperkitty using default
Traceback (most recent call last):
File "/usr/lib/python3.11/site-packages/haystack/management/commands/update_index.py", line 297, in handle
self.update_backend(label, using)
File "/usr/lib/python3.11/site-packages/haystack/management/commands/update_index.py", line 342, in update_backend
max_pk = do_update(
^^^^^^^^^^
File "/usr/lib/python3.11/site-packages/haystack/management/commands/update_index.py", line 119, in do_update
backend.update(index, current_qs, commit=commit)
File "/usr/lib/python3.11/site-packages/xapian_backend.py", line 98, in wrapper
func(self, *args, **kwargs)
File "/usr/lib/python3.11/site-packages/xapian_backend.py", line 505, in update
database.replace_document(document_id, document)
xapian.InvalidArgumentError: Term too long (> 245): XSUBJECThttp://www.google.com/url?q=%68%74%74%70%73%3a%2f%2f%68%64%72%65%64…
Traceback (most recent call last):
File "/opt/mailman-web/./manage.py", line 10, in <module>
execute_from_command_line(sys.argv)
File "/usr/lib/python3.11/site-packages/django/core/management/__init__.py", line 446, in execute_from_command_line
utility.execute()
File "/usr/lib/python3.11/site-packages/django/core/management/__init__.py", line 440, in execute
self.fetch_command(subcommand).run_from_argv(self.argv)
File "/usr/lib/python3.11/site-packages/django/core/management/base.py", line 402, in run_from_argv
self.execute(*args, **cmd_options)
File "/usr/lib/python3.11/site-packages/django/core/management/base.py", line 448, in execute
output = self.handle(*args, **options)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3.11/site-packages/haystack/management/commands/rebuild_index.py", line 65, in handle
call_command("update_index", **update_options)
File "/usr/lib/python3.11/site-packages/django/core/management/__init__.py", line 198, in call_command
return command.execute(*args, **defaults)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3.11/site-packages/django/core/management/base.py", line 448, in execute
output = self.handle(*args, **options)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3.11/site-packages/haystack/management/commands/update_index.py", line 297, in handle
self.update_backend(label, using)
File "/usr/lib/python3.11/site-packages/haystack/management/commands/update_index.py", line 342, in update_backend
max_pk = do_update(
^^^^^^^^^^
File "/usr/lib/python3.11/site-packages/haystack/management/commands/update_index.py", line 119, in do_update
backend.update(index, current_qs, commit=commit)
File "/usr/lib/python3.11/site-packages/xapian_backend.py", line 98, in wrapper
func(self, *args, **kwargs)
File "/usr/lib/python3.11/site-packages/xapian_backend.py", line 505, in update
database.replace_document(document_id, document)
xapian.InvalidArgumentError: Term too long (> 245): XSUBJECThttp://www.google.com/url?q=%68%74%74%70%73%3a%2f%2f%68%64%72%65%64…
----
1 year, 4 months

[MM3-users] Re: External MTA incoming mail: configuration
by Odhiambo Washington
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:
> > 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.
>
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.g roland(a)gtahardware.co.za, johndoe(a)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 to XXX(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.
--
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

[MM3-users] Re: Custom templates (was: Re: Re: nginx configuration on a multitasking server)
by David Newman
On 1/14/22 4:54 PM, Mark Sapiro wrote:
> On 1/14/22 11:56 AM, David Newman wrote:
>>
>> 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}/
>
> This looks like a Mailman 2.1 URL. Are you sure you don't want something
> like
>
> https://${domain}/mailman3/lists/${short_listname}.${domain}/
Yes. The server redirects MM3-style requests to MM2.1 URLs. I need to
determine why, but that may be a different issue than the templates one.
There's nothing obvious in this vhost's nginx config that would generate
the redirect. Will check, if I can't resolve this I'll open a different
thread.
>
>>
>> to approve or deny the request.
>>
>> ----------
>>
>> Instead the message that goes out at midnight daily reads like this:
>
>
> That's a different message. It is sent from the `mailman notify` command
> run by cron. It's built from the list:admin:notice:pending template.
OK, wrong template then.
>
>>
>> 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
>
> I hope you mean
>
> /opt/mailman/mm/var/templates/lists/test.lists.domain.tld/en
Yes
>
>> /opt/mailman/mm/var/templates/site/en
>
>
> Either of those should work. The lists one will take priority over the
> site one for that list.
>
>
>> and then in Postorius, with the same contents as above.
>
> If you set a template in Postorius, it takes priority. If you later
> decide you want to use one in /opt/mailman/mm/var/templates/ you have to
> delete the postorius one.
>
>
>> 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?
>
>
> It should work. I suspect you need to go to the list's Settings ->
> Automatic Responses and set `Admin immed notify` to Yes.
It's enabled. I think this triggers notifications only for new
subscription requests, not pending ones.
>
>
>> 2. Is there a way to trigger a subscribe reminder for one list only?
>
>
> If by subscribe reminder you mean the `list:admin:action:subscribe.txt`
> message, yes that's the above list setting. If you mean the one sent
> from the `mailman notify` command, see `mailman notify --help` for the
> options. You can specify one or more lists (default is all lists) via
> options and put them in your cron.
>
>
>> 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.
>
>
> You can test `mailman notify` at any time by running it by hand.
Thanks. This still isn't working as intended. I took these steps:
1. Created the file
'/opt/mailman/mm/var/templates/lists/test.lists.domain.tld/en/list:admin:action:pending.txt'
with these contents (minus the hyphens top and bottom):
----------
The $listname list has $count moderation requests waiting.
$data
At your convenience, visit:
https://${domain}/mailman3/lists/${short_listname}.${domain}/
to approve or deny the request.
----------
2. Restarted the mailman3 and mailmanweb services
3. As the mailman user, ran the command 'mailman notify -l
test.lists.domain.tld -v'
This generated an email message but its contents were the same as in my
previous post:
----------
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.
----------
What I'm trying to do here is replicate a feature from MM2.1, where
pending notifications had URLs embedded in the message. That's not
available out of the box in MM3, and if there's a place for feature
requests I'd be glad to ask that this be made the default.
For now, though, I'm looking to get this customization working.
Thanks.
dn
3 years, 4 months