From 45d817289a10b3f8ae45e3e6864829ad9f2796db Mon Sep 17 00:00:00 2001 From: "Daniel (dB.) Doubrovkine" Date: Wed, 25 Sep 2024 23:47:22 +0200 Subject: [PATCH] Update dev guide, lock aiohttp to a version that works. (#828) * Update developer guide with test setup instructions using OpenSearch 2.12+. Signed-off-by: dblock * Lock down aiohttp to <= 3.10.5. Signed-off-by: dblock * Exclude failing integ test. Signed-off-by: dblock --------- Signed-off-by: dblock --- DEVELOPER_GUIDE.md | 4 ++-- dev-requirements.txt | 2 +- test_opensearchpy/test_server/test_rest_api_spec.py | 1 + 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/DEVELOPER_GUIDE.md b/DEVELOPER_GUIDE.md index 521a6c20..ec7d220d 100644 --- a/DEVELOPER_GUIDE.md +++ b/DEVELOPER_GUIDE.md @@ -38,7 +38,7 @@ docker pull opensearchproject/opensearch:latest Integration tests will auto-start the docker image. To start it manually: ``` -docker run -d -p 9200:9200 -p 9600:9600 -e "discovery.type=single-node" opensearchproject/opensearch:latest +docker run -d -p 9200:9200 -p 9600:9600 -e OPENSEARCH_INITIAL_ADMIN_PASSWORD=myStrongPassword123! -e "discovery.type=single-node" opensearchproject/opensearch:latest ``` ## Running Tests @@ -54,7 +54,7 @@ python setup.py test To run tests in a specific test file. ``` -python setup.py test -s test_opensearchpy/test_connection.py +python setup.py test -s test_opensearchpy/test_connection/test_base_connection.py ``` If you want to auto-start one, the following will start a new instance and run tests against the latest version of OpenSearch. diff --git a/dev-requirements.txt b/dev-requirements.txt index b1383be9..81a288f1 100644 --- a/dev-requirements.txt +++ b/dev-requirements.txt @@ -20,6 +20,6 @@ black>=24.3.0 twine # Requirements for testing [async] extra -aiohttp>=3.9.4, <4 +aiohttp>=3.9.4, <=3.10.5 pytest-asyncio<=0.24.0 unasync diff --git a/test_opensearchpy/test_server/test_rest_api_spec.py b/test_opensearchpy/test_server/test_rest_api_spec.py index e40c4e09..9783ec37 100644 --- a/test_opensearchpy/test_server/test_rest_api_spec.py +++ b/test_opensearchpy/test_server/test_rest_api_spec.py @@ -85,6 +85,7 @@ "OpenSearch-main/rest-api-spec/src/main/resources/rest-api-spec/test/search/340_doc_values_field[0]", "OpenSearch-main/rest-api-spec/src/main/resources/rest-api-spec/test/search/340_doc_values_field[1]", "OpenSearch-main/rest-api-spec/src/main/resources/rest-api-spec/test/search/aggregation/20_terms[4]", + "OpenSearch-main/rest-api-spec/src/main/resources/rest-api-spec/test/search/aggregation/410_nested_aggs[0]", "OpenSearch-main/rest-api-spec/src/main/resources/rest-api-spec/test/tasks/list/10_basic[0]", }