MOTOR-1477 Add workaround for missing compression.zstd (#353)

This commit is contained in:
Steven Silvester 2025-10-07 12:28:47 -05:00 committed by GitHub
parent 52234081fb
commit 224da029d5
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -18,10 +18,22 @@ import asyncio
import datetime
import email
import logging
import sys
import test
import time
from test.asyncio_tests import AsyncIOTestCase, asyncio_test
import pytest
# MOTOR-1477 - after libzstd is supported on build hosts
# we can remove this guard.
if sys.version_info >= (3, 14):
try:
import compression.zstd # noqa: F401
except ModuleNotFoundError:
pytest.skip(allow_module_level=True)
import aiohttp
import aiohttp.web
import gridfs