Forbid Elasticsearch 8 client or server (#780)

This commit is contained in:
Quentin Pradet 2025-04-30 16:25:33 +04:00 committed by GitHub
parent f5c2dcfc9d
commit 3c3ffd7403
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 3 additions and 8 deletions

View File

@ -236,14 +236,9 @@ def check_cluster_version(es_client, logger):
f"Elasticsearch version {major_version} does not support NLP models. Please upgrade Elasticsearch to the latest version"
)
exit(1)
# PyTorch was upgraded to version 2.3.1 in 8.15.2
# and is incompatible with earlier versions
if sem_ver < (8, 15, 2):
import torch
elif major_version < 9:
logger.error(
f"Eland uses PyTorch version {torch.__version__} which is incompatible with Elasticsearch versions prior to 8.15.2. Please upgrade Elasticsearch to at least version 8.15.2"
"Eland 9.x does not support Elasticsearch 8.x. Please upgrade Elasticsearch first."
)
exit(1)

View File

@ -86,7 +86,7 @@ setup(
keywords="elastic eland pandas python",
packages=find_packages(include=["eland", "eland.*"]),
install_requires=[
"elasticsearch>=8.3,<9",
"elasticsearch>=9,<10",
"pandas>=1.5,<3",
"matplotlib>=3.6",
"numpy>=1.2.0,<2",