{"id":24004,"library":"mailman","title":"Mailman","description":"Mailman is the GNU mailing list manager, a Python library for running and managing mailing lists. Current version 3.3.10, released periodically with bug fixes and improvements.","status":"active","version":"3.3.10","language":"python","source_language":"en","source_url":"https://gitlab.com/mailman/mailman","tags":["mailing list","email","gnu"],"install":[{"cmd":"pip install mailman","lang":"bash","label":"Install Mailman"}],"dependencies":[],"imports":[{"note":"Top-level import is sufficient; direct submodule imports may break if internal structure changes.","wrong":"from mailman import core","symbol":"mailman","correct":"import mailman"},{"note":"IMailingList is the interface; model classes are internal and not part of the public API.","wrong":"from mailman.model import MailingList","symbol":"IMailingList","correct":"from mailman.interfaces import IMailingList"}],"quickstart":{"code":"import os\nfrom mailman.config import config\n\n# Initialize with a configuration file\nconfig.load(os.environ.get('MAILMAN_CONFIG', '/etc/mailman.cfg'))\n\n# Get a mailing list instance (example)\nfrom mailman.interfaces import IMailingList\n# Assuming a list exists\nlist_name = 'my-list'\nmlist = config.db.list_store.get(list_name)\nprint(f'List: {mlist.fqdn_listname}')","lang":"python","description":"Initialize Mailman from config and access a mailing list."},"warnings":[{"fix":"Use the new REST API and library interfaces. See documentation for migration.","message":"Mailman 3.x is a complete rewrite from 2.x; APIs are not compatible. Do not expect Mailman 2.x patterns to work.","severity":"breaking","affected_versions":">=3.0.0"},{"fix":"Use mailman.client (REST client) or mailman.interfaces for operations.","message":"Direct database manipulation is deprecated; use the REST API or the library's public interfaces.","severity":"deprecated","affected_versions":">=3.3.0"},{"fix":"Always call config.load('/path/to/mailman.cfg') early in your script.","message":"Configuration must be loaded before accessing any components. Forgetting config.load() will raise errors.","severity":"gotcha","affected_versions":"all"}],"env_vars":null,"last_verified":"2026-05-01T00:00:00.000Z","next_check":"2026-07-30T00:00:00.000Z","problems":[{"fix":"pip install mailman","cause":"mailman is not installed or not in Python path.","error":"ImportError: No module named mailman"},{"fix":"Set MAILMAN_CONFIG environment variable or pass path existing cfg file.","cause":"config.load() called without a valid path or MAILMAN_CONFIG not set.","error":"ConfigurationError: No configuration file found."},{"fix":"Create the list first via REST API or mailman.core.initialize.","cause":"The list does not exist in the database.","error":"KeyError: 'my-list'"}],"ecosystem":"pypi","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}