[Pkg-mailman-hackers] Bug#1053502: mailman3-web: Package failed to install during upgrade from Debian 11 to 12

arnaud arnaud at arnaudcordier.org
Tue Mar 5 14:28:50 GMT 2024


Hi,

I had the «same issue» upgrading from debian 11 to 12, package 
mailman3-web failed in postconf.


What I found was:

With a config /etc/mailman3/mailman-web.py with this in it :
# EMAILNAME = 'localhost.local'
EMAILNAME = 'lists.example.com'

In /var/cache/debconf/config.dat I get

Name: mailman3-web/emailname
Template: mailman3-web/emailname
Value: #localhost.local
Owners: mailman3-web, unknown
Flags: seen

And then mailman3-web.postinst crashes when it tries to get 
mailman3-web/emailname variable.


I changed my config deleting the commented line, but I think the real 
issue is with get_config_option() in mailman3-web.config

It also worked by changing the sed regex in mailman3-web.config :
=>  s/^\s*$option\s*=\s*'\(.*\)'\s*$/\1/

Or by using python to get the config variable:
=> python3 -c "from importlib.machinery import 
SourceFileLoader;mail=SourceFileLoader('mailman-web','/etc/mailman3/mailman-web.py').load_module();print(mail.${option});"


Thanks for your work.
ArnAud.



More information about the Pkg-mailman-hackers mailing list