Xapian error on RHEL9 - module 'xapian' has no attribute 'QueryParser'

Hi,
I'm trying to set up Mailman 3 on a RHEL9 (unfortunately Debian/Ubuntu aren't options) and have been making some progress, but I'm having trouble getting Xapian to work.
I first tried to install it using Method 1 (https://docs.mailman3.org/en/latest/install/virtualenv.html#set-up-xapian), however, xapian_wheel_builder.sh seems to just exit right as it starts "preparing xapian wheel...".
I ended up installing Xapian 1.4.29 from source and symlinking xapian in the venv as per Method 2.
When trying to search the archives the error below is generated.
Has anyone else encountered this before?
Thanks.
#################################################################################
Internal Server Error: /archives/search
AttributeError at /archives/search module 'xapian' has no attribute 'QueryParser'
Request Method: GET Request URL: https://mailinglists-dev.ucl.ac.uk/archives/search?mlist=skgtlmr-test%40mailinglists-dev.ucl.ac.uk&q=foo Django Version: 4.2.23 Python Executable: /opt/mailman/venv/bin/python3.12 Python Version: 3.12.9 Python Path: ['/opt/mailman/mm', '/', '/opt/mailman/venv/bin', '/etc/mailman3', '/usr/lib64/python312.zip', '/usr/lib64/python3.12', '/usr/lib64/python3.12/lib-dynload', '/opt/mailman/venv/lib64/python3.12/site-packages', '/opt/mailman/venv/lib/python3.12/site-packages', '/etc/mailman3'] Server time: Thu, 21 Aug 2025 11:05:02 +0100 Installed Applications: ['hyperkitty', 'postorius', 'django_mailman3', 'django.contrib.admin', 'django.contrib.auth', 'django.contrib.contenttypes', 'django.contrib.sessions', 'django.contrib.sites', 'django.contrib.messages', 'django.contrib.staticfiles', 'django.contrib.humanize', 'rest_framework', 'django_gravatar', 'compressor', 'haystack', 'django_extensions', 'django_q', 'allauth', 'allauth.account', 'allauth.socialaccount'] Installed Middleware: ('allauth.account.middleware.AccountMiddleware', 'django.contrib.sessions.middleware.SessionMiddleware', 'django.middleware.common.CommonMiddleware', 'django.middleware.csrf.CsrfViewMiddleware', 'django.middleware.locale.LocaleMiddleware', 'django.contrib.auth.middleware.AuthenticationMiddleware', 'django.contrib.messages.middleware.MessageMiddleware', 'django.middleware.clickjacking.XFrameOptionsMiddleware', 'django.middleware.security.SecurityMiddleware', 'django_mailman3.middleware.TimezoneMiddleware', 'postorius.middleware.PostoriusMiddleware')
Traceback (most recent call last): File "/opt/mailman/venv/lib64/python3.12/site-packages/django/core/handlers/exception.py", line 55, in inner response = get_response(request) ^^^^^^^^^^^^^^^^^^^^^ File "/opt/mailman/venv/lib64/python3.12/site-packages/django/core/handlers/base.py", line 197, in _get_response response = wrapped_callback(request, *callback_args, **callback_kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/opt/mailman/venv/lib64/python3.12/site-packages/hyperkitty/views/search.py", line 54, in search results = EmptySearchQuerySet() ^^^^^^^^^^^^^^^^^^^^^ File "/opt/mailman/venv/lib64/python3.12/site-packages/haystack/query.py", line 25, in __init__ self._determine_backend() ^^^^^^^^^^^^^^^^^^^^^^^^^ File "/opt/mailman/venv/lib64/python3.12/site-packages/haystack/query.py", line 58, in _determine_backend self.query = connections[backend_alias].get_query() ^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/opt/mailman/venv/lib64/python3.12/site-packages/haystack/utils/loading.py", line 114, in __getitem__ self.thread_local.connections[key] = load_backend( File "/opt/mailman/venv/lib64/python3.12/site-packages/haystack/utils/loading.py", line 60, in load_backend return import_class(full_backend_path) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/opt/mailman/venv/lib64/python3.12/site-packages/haystack/utils/loading.py", line 22, in import_class module_itself = importlib.import_module(module_path) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.12/importlib/__init__.py", line 90, in import_module return _bootstrap._gcd_import(name[level:], package, level) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "<frozen importlib._bootstrap>", line 1387, in _gcd_import <source code not available> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "<frozen importlib._bootstrap>", line 1360, in _find_and_load <source code not available> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "<frozen importlib._bootstrap>", line 1331, in _find_and_load_unlocked <source code not available> ^^^^^^^^^^^^^^^^^^^^ File "<frozen importlib._bootstrap>", line 935, in _load_unlocked <source code not available> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "<frozen importlib._bootstrap_external>", line 999, in exec_module <source code not available> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "<frozen importlib._bootstrap>", line 488, in _call_with_frames_removed <source code not available> ^^^^^^^^^^^^^^^^ File "/opt/mailman/venv/lib64/python3.12/site-packages/xapian_backend.py", line 50, in <module> xapian.QueryParser.FLAG_PHRASE | ^^^^^^^^^^^^^^^^^^
Exception Type: AttributeError at /archives/search Exception Value: module 'xapian' has no attribute 'QueryParser' Raised during: hyperkitty.views.search.search Request information: USER: skgtlmr
GET: mlist = 'skgtlmr-test@mailinglists-dev.ucl.ac.uk' q = 'foo'
POST: No POST data
FILES: No FILES data
COOKIES: EBSLIV = 'UQjksgWK7Zyd5TfaUK4KgP5PzD' _scid = 'A90JyW0nIFAyPsZyxkyUhTRixUN9PurngTShxQ' cookie-agreed-version = '1.0.0' cookie-agreed-categories = '%5B%22necessary_cookies%22%2C%22analytics_and_customisation_cookies%22%2C%22advertising_cookies%22%5D' cookie-agreed = '2' _fbp = 'fb.2.1752842717574.837640545407184978' nmstat = 'cd7efb87-0f9e-afb5-fbad-f9f4bc1769b8' _ga_QQBYV15T88 = 'GS2.3.s1753165359$o2$g1$t1753165373$j46$l0$h0' __utmc = '156947391' __utmz = '156947391.1753782039.4.2.utmcsr=google|utmccn=(organic)|utmcmd=organic|utmctr=(not%20provided)' _ga_NWBZGPY11C = 'GS2.1.s1753799417$o1$g1$t1753800249$j11$l0$h0' __utma = '156947391.1941193546.1752485543.1753782039.1753863655.5' _ga_WV6RVXXKPJ = 'GS2.1.s1755086211$o3$g0$t1755086216$j55$l0$h0' _ga_P316Z5TR5Q = 'GS2.1.s1755161312$o2$g1$t1755161324$j48$l0$h0' csrftoken = '********************' sessionid = '********************' _ga = 'GA1.1.1941193546.1752485543' _ga_35DML57W9V = 'GS2.1.s1755180982$o22$g1$t1755181740$j60$l0$h0'
META: CSRF_COOKIE = 'jtklayWS008FhjoaikeHZmhSLZekOKkN' HTTP_ACCEPT = 'text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.7' HTTP_ACCEPT_ENCODING = 'gzip, deflate, br, zstd' HTTP_ACCEPT_LANGUAGE = 'en-GB,en-US;q=0.9,en;q=0.8' HTTP_CONNECTION = 'Keep-Alive' HTTP_COOKIE = '********************' HTTP_HOST = 'mailinglists-dev.ucl.ac.uk' HTTP_REFERER = 'https://mailinglists-dev.ucl.ac.uk/archives/list/skgtlmr-test@mailinglists-d...' HTTP_SEC_CH_UA = '"Not)A;Brand";v="8", "Chromium";v="138", "Google Chrome";v="138"' HTTP_SEC_CH_UA_MOBILE = '?0' HTTP_SEC_CH_UA_PLATFORM = '"Windows"' HTTP_SEC_FETCH_DEST = 'document' HTTP_SEC_FETCH_MODE = 'navigate' HTTP_SEC_FETCH_SITE = 'same-origin' HTTP_SEC_FETCH_USER = '?1' HTTP_UPGRADE_INSECURE_REQUESTS = '1' HTTP_USER_AGENT = 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/138.0.0.0 Safari/537.36' HTTP_X_FORWARDED_FOR = '10.0.115.196' HTTP_X_FORWARDED_HOST = 'mailinglists-dev.ucl.ac.uk' HTTP_X_FORWARDED_PROTO = 'https' HTTP_X_FORWARDED_SERVER = 'mail-man03d.addev.ucl.ac.uk' PATH_INFO = '/archives/search' QUERY_STRING = 'mlist=skgtlmr-test%40mailinglists-dev.ucl.ac.uk&q=foo' RAW_URI = '/archives/search?mlist=skgtlmr-test%40mailinglists-dev.ucl.ac.uk&q=foo' REMOTE_ADDR = '127.0.0.1' REMOTE_PORT = '41572' REQUEST_METHOD = 'GET' SCRIPT_NAME = '' SERVER_NAME = '127.0.0.1' SERVER_PORT = '8000' SERVER_PROTOCOL = 'HTTP/1.1' SERVER_SOFTWARE = 'gunicorn/23.0.0' gunicorn.socket = <socket.socket fd=4, family=2, type=1, proto=0, laddr=('127.0.0.1', 8000), raddr=('127.0.0.1', 41572)> wsgi.errors = <gunicorn.http.wsgi.WSGIErrorsWrapper object at 0x7f9096342ec0> wsgi.file_wrapper = <class 'gunicorn.http.wsgi.FileWrapper'> wsgi.input = <gunicorn.http.body.Body object at 0x7f909652b020> wsgi.input_terminated = True wsgi.multiprocess = False wsgi.multithread = False wsgi.run_once = False wsgi.url_scheme = 'https' wsgi.version = '(1, 0)'
Settings: Using settings module settings ABSOLUTE_URL_OVERRIDES = {} ACCOUNT_AUTHENTICATION_METHOD = 'username_email' ACCOUNT_DEFAULT_HTTP_PROTOCOL = 'http' ACCOUNT_EMAIL_REQUIRED = True ACCOUNT_EMAIL_UNKNOWN_ACCOUNTS = False ACCOUNT_EMAIL_VERIFICATION = 'mandatory' ACCOUNT_LOGIN_METHODS = {'username', 'email'} ACCOUNT_SIGNUP_FIELDS = ['username*', 'email*', 'password1*', 'password2*'] ACCOUNT_UNIQUE_EMAIL = True ADMINS = "(('Mailman Suite Admin', 'root@localhost'), ('Cloud Platforms Admin', 'l.reilly@ucl.ac.uk'))" ALLOWED_HOSTS = ['localhost', '127.0.0.1', '*'] APPEND_SLASH = True AUTHENTICATION_BACKENDS = "('django.contrib.auth.backends.ModelBackend', 'allauth.account.auth_backends.AuthenticationBackend')" AUTH_PASSWORD_VALIDATORS = '********************' AUTH_USER_MODEL = 'auth.User' BASE_DIR = PosixPath('/opt/mailman/web') CACHES = {'default': {'BACKEND': 'django.core.cache.backends.locmem.LocMemCache'}} CACHE_MIDDLEWARE_ALIAS = 'default' CACHE_MIDDLEWARE_KEY_PREFIX = '********************' CACHE_MIDDLEWARE_SECONDS = 600 COMPRESSORS = {'css': 'compressor.css.CssCompressor', 'js': 'compressor.js.JsCompressor'} COMPRESS_CACHEABLE_PRECOMPILERS = '()' COMPRESS_CACHE_BACKEND = 'default' COMPRESS_CACHE_KEY_FUNCTION = '********************' COMPRESS_CLEAN_CSS_ARGUMENTS = '' COMPRESS_CLEAN_CSS_BINARY = 'cleancss' COMPRESS_CLOSURE_COMPILER_ARGUMENTS = '' COMPRESS_CLOSURE_COMPILER_BINARY = 'java -jar compiler.jar' COMPRESS_CSS_HASHING_METHOD = 'mtime' COMPRESS_DATA_URI_MAX_SIZE = 1024 COMPRESS_DEBUG_TOGGLE = None COMPRESS_ENABLED = True COMPRESS_FILTERS = {'css': ['compressor.filters.css_default.CssAbsoluteFilter', 'compressor.filters.cssmin.rCSSMinFilter'], 'js': ['compressor.filters.jsmin.rJSMinFilter']} COMPRESS_JINJA2_GET_ENVIRONMENT = <function CompressorConf.JINJA2_GET_ENVIRONMENT at 0x7f9097504fe0> COMPRESS_MINT_DELAY = 30 COMPRESS_MTIME_DELAY = 10 COMPRESS_OFFLINE = True COMPRESS_OFFLINE_CONTEXT = {'STATIC_URL': '/static/'} COMPRESS_OFFLINE_MANIFEST = 'manifest.json' COMPRESS_OFFLINE_MANIFEST_STORAGE = 'compressor.storage.OfflineManifestFileStorage' COMPRESS_OFFLINE_MANIFEST_STORAGE_ALIAS = 'compressor-offine' COMPRESS_OFFLINE_TIMEOUT = 31536000 COMPRESS_OUTPUT_DIR = 'CACHE' COMPRESS_PARSER = 'compressor.parser.AutoSelectParser' COMPRESS_PRECOMPILERS = "(('text/x-scss', 'sassc -t compressed {infile} {outfile}'), ('text/x-sass', 'sassc -t compressed {infile} {outfile}'))" COMPRESS_REBUILD_TIMEOUT = 2592000 COMPRESS_ROOT = '/opt/mailman/web/static' COMPRESS_STORAGE = 'compressor.storage.CompressorFileStorage' COMPRESS_STORAGE_ALIAS = 'compressor' COMPRESS_TEMPLATE_FILTER_CONTEXT = {'STATIC_URL': '/static/'} COMPRESS_URL = '/static/' COMPRESS_URL_PLACEHOLDER = '/__compressor_url_placeholder__/' COMPRESS_VERBOSE = False COMPRESS_YUGLIFY_BINARY = 'yuglify' COMPRESS_YUGLIFY_CSS_ARGUMENTS = '--terminal' COMPRESS_YUGLIFY_JS_ARGUMENTS = '--terminal' COMPRESS_YUI_BINARY = 'java -jar yuicompressor.jar' COMPRESS_YUI_CSS_ARGUMENTS = '' COMPRESS_YUI_JS_ARGUMENTS = '' CSRF_COOKIE_AGE = 31449600 CSRF_COOKIE_DOMAIN = None CSRF_COOKIE_HTTPONLY = False CSRF_COOKIE_MASKED = False CSRF_COOKIE_NAME = 'csrftoken' CSRF_COOKIE_PATH = '/' CSRF_COOKIE_SAMESITE = 'Lax' CSRF_COOKIE_SECURE = False CSRF_FAILURE_VIEW = 'django.views.csrf.csrf_failure' CSRF_HEADER_NAME = 'HTTP_X_CSRFTOKEN' CSRF_TRUSTED_ORIGINS = [] CSRF_USE_SESSIONS = False DATABASES = {'default': {'ENGINE': 'django.db.backends.postgresql_psycopg2', 'NAME': 'mailmanweb', 'USER': 'mailman', 'PASSWORD': '********************', 'HOST': 'localhost', 'PORT': '5432', 'ATOMIC_REQUESTS': False, 'AUTOCOMMIT': True, 'CONN_MAX_AGE': 0, 'CONN_HEALTH_CHECKS': False, 'OPTIONS': {}, 'TIME_ZONE': None, 'TEST': {'CHARSET': None, 'COLLATION': None, 'MIGRATE': True, 'MIRROR': None, 'NAME': None}}} DATABASE_ROUTERS = [] DATA_UPLOAD_MAX_MEMORY_SIZE = 2621440 DATA_UPLOAD_MAX_NUMBER_FIELDS = 1000 DATA_UPLOAD_MAX_NUMBER_FILES = 100 DATETIME_FORMAT = 'N j, Y, P' DATETIME_INPUT_FORMATS = ['%Y-%m-%d %H:%M:%S', '%Y-%m-%d %H:%M:%S.%f', '%Y-%m-%d %H:%M', '%m/%d/%Y %H:%M:%S', '%m/%d/%Y %H:%M:%S.%f', '%m/%d/%Y %H:%M', '%m/%d/%y %H:%M:%S', '%m/%d/%y %H:%M:%S.%f', '%m/%d/%y %H:%M'] DATE_FORMAT = 'N j, Y' DATE_INPUT_FORMATS = ['%Y-%m-%d', '%m/%d/%Y', '%m/%d/%y', '%b %d %Y', '%b %d, %Y', '%d %b %Y', '%d %b, %Y', '%B %d %Y', '%B %d, %Y', '%d %B %Y', '%d %B, %Y'] DEBUG = False DEBUG_PROPAGATE_EXCEPTIONS = False DECIMAL_SEPARATOR = '.' DEFAULT_AUTO_FIELD = 'django.db.models.AutoField' DEFAULT_CHARSET = 'utf-8' DEFAULT_EXCEPTION_REPORTER = 'django.views.debug.ExceptionReporter' DEFAULT_EXCEPTION_REPORTER_FILTER = 'django.views.debug.SafeExceptionReporterFilter' DEFAULT_FILE_STORAGE = 'django.core.files.storage.FileSystemStorage' DEFAULT_FROM_EMAIL = 'mailman@ucl.ac.uk' DEFAULT_INDEX_TABLESPACE = '' DEFAULT_TABLESPACE = '' DISALLOWED_USER_AGENTS = [] EMAIL_BACKEND = 'django.core.mail.backends.smtp.EmailBackend' EMAIL_HOST = '*************' EMAIL_HOST_PASSWORD = '********************' EMAIL_HOST_USER = '' EMAIL_PORT = 25 EMAIL_SSL_CERTFILE = None EMAIL_SSL_KEYFILE = '********************' EMAIL_SUBJECT_PREFIX = '[Django] ' EMAIL_TIMEOUT = None EMAIL_USE_LOCALTIME = False EMAIL_USE_SSL = False EMAIL_USE_TLS = False FILE_UPLOAD_DIRECTORY_PERMISSIONS = None FILE_UPLOAD_HANDLERS = ['django.core.files.uploadhandler.MemoryFileUploadHandler', 'django.core.files.uploadhandler.TemporaryFileUploadHandler'] FILE_UPLOAD_MAX_MEMORY_SIZE = 2621440 FILE_UPLOAD_PERMISSIONS = 420 FILE_UPLOAD_TEMP_DIR = None FILTER_VHOST = False FIRST_DAY_OF_WEEK = 0 FIXTURE_DIRS = [] FORCE_SCRIPT_NAME = None FORMAT_MODULE_PATH = None FORM_RENDERER = 'django.forms.renderers.DjangoTemplates' HAYSTACK_CONNECTIONS = {'default': {'PATH': '/opt/mailman/web/xapian_index', 'ENGINE': 'xapian_backend.XapianEngine'}} HYPERKITTY_ENABLE_GRAVATAR = False IGNORABLE_404_URLS = [] INSTALLED_APPS = ['hyperkitty', 'postorius', 'django_mailman3', 'django.contrib.admin', 'django.contrib.auth', 'django.contrib.contenttypes', 'django.contrib.sessions', 'django.contrib.sites', 'django.contrib.messages', 'django.contrib.staticfiles', 'django.contrib.humanize', 'rest_framework', 'django_gravatar', 'compressor', 'haystack', 'django_extensions', 'django_q', 'allauth', 'allauth.account', 'allauth.socialaccount'] INTERNAL_IPS = [] LANGUAGES = [('af', 'Afrikaans'), ('ar', 'Arabic'), ('ar-dz', 'Algerian Arabic'), ('ast', 'Asturian'), ('az', 'Azerbaijani'), ('bg', 'Bulgarian'), ('be', 'Belarusian'), ('bn', 'Bengali'), ('br', 'Breton'), ('bs', 'Bosnian'), ('ca', 'Catalan'), ('ckb', 'Central Kurdish (Sorani)'), ('cs', 'Czech'), ('cy', 'Welsh'), ('da', 'Danish'), ('de', 'German'), ('dsb', 'Lower Sorbian'), ('el', 'Greek'), ('en', 'English'), ('en-au', 'Australian English'), ('en-gb', 'British English'), ('eo', 'Esperanto'), ('es', 'Spanish'), ('es-ar', 'Argentinian Spanish'), ('es-co', 'Colombian Spanish'), ('es-mx', 'Mexican Spanish'), ('es-ni', 'Nicaraguan Spanish'), ('es-ve', 'Venezuelan Spanish'), ('et', 'Estonian'), ('eu', 'Basque'), ('fa', 'Persian'), ('fi', 'Finnish'), ('fr', 'French'), ('fy', 'Frisian'), ('ga', 'Irish'), ('gd', 'Scottish Gaelic'), ('gl', 'Galician'), ('he', 'Hebrew'), ('hi', 'Hindi'), ('hr', 'Croatian'), ('hsb', 'Upper Sorbian'), ('hu', 'Hungarian'), ('hy', 'Armenian'), ('ia', 'Interlingua'), ('id', 'Indonesian'), ('ig', 'Igbo'), ('io', 'Ido'), ('is', 'Icelandic'), ('it', 'Italian'), ('ja', 'Japanese'), ('ka', 'Georgian'), ('kab', 'Kabyle'), ('kk', 'Kazakh'), ('km', 'Khmer'), ('kn', 'Kannada'), ('ko', 'Korean'), ('ky', 'Kyrgyz'), ('lb', 'Luxembourgish'), ('lt', 'Lithuanian'), ('lv', 'Latvian'), ('mk', 'Macedonian'), ('ml', 'Malayalam'), ('mn', 'Mongolian'), ('mr', 'Marathi'), ('ms', 'Malay'), ('my', 'Burmese'), ('nb', 'Norwegian Bokmål'), ('ne', 'Nepali'), ('nl', 'Dutch'), ('nn', 'Norwegian Nynorsk'), ('os', 'Ossetic'), ('pa', 'Punjabi'), ('pl', 'Polish'), ('pt', 'Portuguese'), ('pt-br', 'Brazilian Portuguese'), ('ro', 'Romanian'), ('ru', 'Russian'), ('sk', 'Slovak'), ('sl', 'Slovenian'), ('sq', 'Albanian'), ('sr', 'Serbian'), ('sr-latn', 'Serbian Latin'), ('sv', 'Swedish'), ('sw', 'Swahili'), ('ta', 'Tamil'), ('te', 'Telugu'), ('tg', 'Tajik'), ('th', 'Thai'), ('tk', 'Turkmen'), ('tr', 'Turkish'), ('tt', 'Tatar'), ('udm', 'Udmurt'), ('uk', 'Ukrainian'), ('ur', 'Urdu'), ('uz', 'Uzbek'), ('vi', 'Vietnamese'), ('zh-hans', 'Simplified Chinese'), ('zh-hant', 'Traditional Chinese')] LANGUAGES_BIDI = ['he', 'ar', 'ar-dz', 'ckb', 'fa', 'ur'] LANGUAGE_CODE = 'en-us' LANGUAGE_COOKIE_AGE = None LANGUAGE_COOKIE_DOMAIN = None LANGUAGE_COOKIE_HTTPONLY = False LANGUAGE_COOKIE_NAME = 'django_language' LANGUAGE_COOKIE_PATH = '/' LANGUAGE_COOKIE_SAMESITE = None LANGUAGE_COOKIE_SECURE = False LOCALE_PATHS = [] LOGGING = {'version': 1, 'disable_existing_loggers': False, 'filters': {'require_debug_false': {'()': 'django.utils.log.RequireDebugFalse'}}, 'handlers': {'mail_admins': {'level': 'ERROR', 'filters': ['require_debug_false'], 'class': 'django.utils.log.AdminEmailHandler'}, 'file': {'level': 'INFO', 'class': 'logging.handlers.WatchedFileHandler', 'filename': '/opt/mailman/mm/var/logs/mailmanweb.log', 'formatter': 'verbose'}, 'console': {'class': 'logging.StreamHandler', 'formatter': 'simple'}}, 'loggers': {'django.request': {'handlers': ['mail_admins', 'file'], 'level': 'ERROR', 'propagate': True}, 'django': {'handlers': ['file'], 'level': 'ERROR', 'propagate': True}, 'hyperkitty': {'handlers': ['file'], 'level': 'DEBUG', 'propagate': True}, 'postorius': {'handlers': ['console', 'file'], 'level': 'INFO'}, 'q': {'level': 'WARNING', 'propagate': False, 'handlers': ['console', 'file']}}, 'formatters': {'verbose': {'format': '%(levelname)s %(asctime)s %(process)d %(name)s %(message)s'}, 'simple': {'format': '%(levelname)s %(message)s'}}} LOGGING_CONFIG = 'logging.config.dictConfig' LOGIN_REDIRECT_URL = 'list_index' LOGIN_URL = 'account_login' LOGOUT_REDIRECT_URL = None LOGOUT_URL = 'account_logout' MAILMAN_ARCHIVER_FROM = "('127.0.0.1', '::1')" MAILMAN_ARCHIVER_KEY = '********************' MAILMAN_REST_API_PASS = '********************' MAILMAN_REST_API_URL = '********************' MAILMAN_REST_API_USER = '********************' MANAGERS = [] MEDIA_ROOT = '' MEDIA_URL = '/' MESSAGE_STORAGE = 'django.contrib.messages.storage.fallback.FallbackStorage' MESSAGE_TAGS = {40: 'danger'} MIDDLEWARE = "('allauth.account.middleware.AccountMiddleware', 'django.contrib.sessions.middleware.SessionMiddleware', 'django.middleware.common.CommonMiddleware', 'django.middleware.csrf.CsrfViewMiddleware', 'django.middleware.locale.LocaleMiddleware', 'django.contrib.auth.middleware.AuthenticationMiddleware', 'django.contrib.messages.middleware.MessageMiddleware', 'django.middleware.clickjacking.XFrameOptionsMiddleware', 'django.middleware.security.SecurityMiddleware', 'django_mailman3.middleware.TimezoneMiddleware', 'postorius.middleware.PostoriusMiddleware')" MIGRATION_MODULES = {} MONTH_DAY_FORMAT = 'F j' NUMBER_GROUPING = 0 PASSWORD_HASHERS = '********************' PASSWORD_RESET_TIMEOUT = '********************' POSTORIUS_TEMPLATE_BASE_URL = 'http://localhost:8000' PREPEND_WWW = False Q_CLUSTER = {'retry': 360, 'timeout': 300, 'save_limit': 100, 'orm': 'default'} ROOT_URLCONF = 'mailman_web.urls' SECRET_KEY = '********************' SECRET_KEY_FALLBACKS = '********************' SECURE_CONTENT_TYPE_NOSNIFF = True SECURE_CROSS_ORIGIN_OPENER_POLICY = 'same-origin' SECURE_HSTS_INCLUDE_SUBDOMAINS = False SECURE_HSTS_PRELOAD = False SECURE_HSTS_SECONDS = 0 SECURE_PROXY_SSL_HEADER = None SECURE_REDIRECT_EXEMPT = [] SECURE_REFERRER_POLICY = 'same-origin' SECURE_SSL_HOST = None SECURE_SSL_REDIRECT = False SERVER_EMAIL = 'mailman@ucl.ac.uk' SESSION_CACHE_ALIAS = 'default' SESSION_COOKIE_AGE = 1209600 SESSION_COOKIE_DOMAIN = None SESSION_COOKIE_HTTPONLY = True SESSION_COOKIE_NAME = 'sessionid' SESSION_COOKIE_PATH = '/' SESSION_COOKIE_SAMESITE = 'Lax' SESSION_COOKIE_SECURE = False SESSION_ENGINE = 'django.contrib.sessions.backends.db' SESSION_EXPIRE_AT_BROWSER_CLOSE = False SESSION_FILE_PATH = None SESSION_SAVE_EVERY_REQUEST = False SESSION_SERIALIZER = 'django.contrib.sessions.serializers.JSONSerializer' SETTINGS_MODULE = 'settings' SHORT_DATETIME_FORMAT = 'm/d/Y P' SHORT_DATE_FORMAT = 'm/d/Y' SIGNING_BACKEND = 'django.core.signing.TimestampSigner' SILENCED_SYSTEM_CHECKS = [] SITE_ID = 1 SOCIALACCOUNT_PROVIDERS = {'openid': {'SERVERS': [{'id': 'yahoo', 'name': 'Yahoo', 'openid_url': 'https://eur01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fme.yahoo.com%2F&data=05%7C02%7Cl.reilly%40ucl.ac.uk%7C3807ec0bd2c44fdd839608dde09a3202%7C1faf88fea9984c5b93c9210a11d9a5c2%7C0%7C0%7C638913675052119831%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C0%7C%7C%7C&sdata=uqRrp4zgilm82ehc9YBJAQy0kjwKHlhcUmVPSpIRAp4%3D&reserved=0'}]}, 'google': {'SCOPE': ['profile', 'email'], 'AUTH_PARAMS': {'access_type': 'online'}}, 'facebook': {'METHOD': 'oauth2', 'SCOPE': ['email'], 'FIELDS': ['email', 'name', 'first_name', 'last_name', 'locale', 'timezone'], 'VERSION': 'v2.4'}} STATICFILES_DIRS = '()' STATICFILES_FINDERS = "('django.contrib.staticfiles.finders.FileSystemFinder', 'django.contrib.staticfiles.finders.AppDirectoriesFinder', 'compressor.finders.CompressorFinder')" STATICFILES_STORAGE = 'django.contrib.staticfiles.storage.StaticFilesStorage' STATIC_ROOT = '/opt/mailman/web/static' STATIC_URL = '/static/' STORAGES = {'default': {'BACKEND': 'django.core.files.storage.FileSystemStorage'}, 'staticfiles': {'BACKEND': 'django.contrib.staticfiles.storage.StaticFilesStorage'}} TEMPLATES = [{'BACKEND': 'django.template.backends.django.DjangoTemplates', 'DIRS': [], 'APP_DIRS': True, 'OPTIONS': {'context_processors': ['django.template.context_processors.debug', 'django.template.context_processors.i18n', 'django.template.context_processors.media', 'django.template.context_processors.static', 'django.template.context_processors.tz', 'django.template.context_processors.csrf', 'django.template.context_processors.request', 'django.contrib.auth.context_processors.auth', 'django.contrib.messages.context_processors.messages', 'django_mailman3.context_processors.common', 'hyperkitty.context_processors.common', 'postorius.context_processors.postorius']}}] TEST_NON_SERIALIZED_APPS = [] TEST_RUNNER = 'django.test.runner.DiscoverRunner' THOUSAND_SEPARATOR = ',' TIME_FORMAT = 'P' TIME_INPUT_FORMATS = ['%H:%M:%S', '%H:%M:%S.%f', '%H:%M'] TIME_ZONE = 'UTC' USE_DEPRECATED_PYTZ = False USE_I18N = True USE_L10N = True USE_THOUSAND_SEPARATOR = False USE_TZ = True USE_X_FORWARDED_HOST = False USE_X_FORWARDED_PORT = False WSGI_APPLICATION = 'mailman_web.wsgi.application' X_FRAME_OPTIONS = 'DENY' YEAR_MONTH_FORMAT = 'F Y'

l.reilly@ucl.ac.uk writes:
I first tried to install it using Method 1 (https://docs.mailman3.org/en/latest/install/virtualenv.html#set-up-xapian), however, xapian_wheel_builder.sh seems to just exit right as it starts "preparing xapian wheel...".
I suppose this probably includes an invocation of "python -m build ...". Try editing the xapian_wheel_builder.sh script to add the "-v" option after "build" to try to get more information about what it did and (I hope) why it didn't. Not sure if multiple "-v" gives more information.
I believe you could also use the distutils build instead of wheel, and ask pip to install that into the venv. (I could be wrong, one of the motivations for wheels was handling installation of binary Python modules and auxiliary DSOs better.)
I ended up installing Xapian 1.4.29 from source and symlinking xapian in the venv as per Method 2.
Method 2 is Debian-specific (it depends on Xapian and python-xapian both being packaged). What exactly did you do?
Has anyone else encountered this before?
I've done the python-xapian build and install for an Ubuntu host with no problem. I used the Ubuntu Xapian package and installed python-xapian directly into the site-packages directory in the venv, though.
I did need to work out a g++ version compatibility problem. I assume you're building the Python bindings in the same tree and at the same time as the main application? If so, you shouldn't have a problem with library version mismatches.
-- GNU Mailman consultant (installation, migration, customization) Sirius Open Source https://www.siriusopensource.com/ Software systems consulting in Europe, North America, and Japan

Hi,
I installed Mailman 3 using the Virtual Installation guide on Rocky Linux 9, which as we all know 100% bug-for-bug compatible with RHEL.
I encountered the same issue when installing Xapian, but I managed to troubleshoot and get Method 1 working.
It's an issue with the xapian_wheel_builder.sh
script. Somewhere in the script it executes a readelf
command and pipes the output to grep RUNPATH
, which in RHEL, RUNPATH is RPATH.
I modified the script with the following and it was able to complete successfully producing the needed xapian-1.4.29-cp312-cp312-linux_x86_64.whl
file. Also, don't forget to create the xapian_index directory.
sed -i 's/RUNPATH/RPATH/' xapian_wheel_builder.sh
bash xapian_wheel_builder.sh -p /usr/bin/python3.12 1.4.29
mkdir -p /opt/mailman/web/xapian_index
-German

Thank you German! Xapian is now working.
We have some pretty large archives that need migrating over from Mailman 2.1 so Whoosh might have not been ideal.
I'd be curious to know if you encountered any more RHEL/Rocky-specific issues with your install (and migration if you came from Mailman 2)?
Cheers.

I looked at my notes and there was one other thing. There's an issue with mailman and postfix when performing email commands.
I had to set the recipient_delimiter
in /etc/postfix/main.cf
recipient_delimiter = +
I believe this is included by default in Debian/Ubuntu after installing Postfix.
I had less than a handful of lists in my Mailman 2 server, so I didn't perform a migration. I just re-created my lists and configured them as closely as possible as they were in Mailman 2.

l.reilly@ucl.ac.uk writes:
We have some pretty large archives that need migrating over from Mailman 2.1 so Whoosh might have not been ideal.
In the migration I mentioned earlier, Xapian indexing of archives was by far the most time-consuming part. At that time I was unable to find a way to work backward (most searches are for recent posts), so I modified the scripts to (1) not index while migrating the posts and (2) prioritize the most active small-archive lists for indexing. I'm not sure I have copies of those scripts any more though.
-- GNU Mailman consultant (installation, migration, customization) Sirius Open Source https://www.siriusopensource.com/ Software systems consulting in Europe, North America, and Japan
participants (3)
-
German Rodriguez
-
l.reilly@ucl.ac.uk
-
Stephen J. Turnbull