Ok, that looked weird, i try again with no python marks.
from mailman.interfaces.styles import IStyleManager manager = getUtility(IStyleManager) from zope.interface import implementer from mailman.interfaces.styles import IStyle @implementer(IStyle) class EcoStyle: name = 'ECOstyle' description = 'ECO mailing list style.' def apply(self, ml): ml.dmarc_mitigate_action = 'munge_from' ml.dmarc_mitigate_unconditionally = 'True' ml.send_welcome_message = 'True' ml.subject_prefix = '' ml.subscription_policy = 'moderate' ml.max_message_size = '0'
manager.register(EcoStyle()) commit()
from zope.component import getUtility from mailman.interfaces.styles import IStyleManager manager = getUtility(IStyleManager)
for style in manager.styles: print(style.name)
ECOstyle legacy-announce legacy-default private-default
quit() ecoadmin@list01:/etc/mailman3$ sudo mailman shell Welcome to the GNU Mailman shell
from zope.component import getUtility from mailman.interfaces.styles import IStyleManager manager = getUtility(IStyleManager)
for style in manager.styles: print(style.name)
legacy-announce legacy-default private-default