From 645a8f2e1d5bdf3131bf009df90eff342364c152 Mon Sep 17 00:00:00 2001 From: Andy Xu Date: Tue, 26 Sep 2023 23:41:15 -0700 Subject: [PATCH] Fix staging CI setup (#1229) - [x] add `time.sleep` in `DummyLLM` to make it run longer for the resue test cases. - [x] always cache even the test is failed. - [x] skip pinecone tests due to free-tier limit. --- .circleci/config.yml | 1 + test/integration_tests/long/test_similarity.py | 1 + test/util.py | 4 +++- 3 files changed, 5 insertions(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 9153ea0815..ecdb84818d 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -253,6 +253,7 @@ jobs: if [[ $PY_VERSION = "3.10" ]] || [[ $PY_VERSION = "3.11" ]]; then export SETUPTOOLS_USE_DISTUTILS=stdlib fi + set +e # To make sure the later cache step is not skipped. bash script/test/test.sh -m "<< parameters.mode >>" # Enable cache save conditionally (to avoid empty cache in Notebooks) diff --git a/test/integration_tests/long/test_similarity.py b/test/integration_tests/long/test_similarity.py index b16278c0cf..5e22cf6651 100644 --- a/test/integration_tests/long/test_similarity.py +++ b/test/integration_tests/long/test_similarity.py @@ -463,6 +463,7 @@ def test_end_to_end_index_scan_should_work_correctly_on_image_dataset_chromadb( drop_query = "DROP INDEX testChromaDBIndexImageDataset" execute_query_fetch_all(self.evadb, drop_query) + @pytest.mark.skip(reason="require pinecone") @pinecone_skip_marker def test_end_to_end_index_scan_should_work_correctly_on_image_dataset_pinecone( self, diff --git a/test/util.py b/test/util.py index e3dba474ed..23eaeb35e8 100644 --- a/test/util.py +++ b/test/util.py @@ -17,6 +17,7 @@ import os import shutil import socket +import time from contextlib import closing from itertools import repeat from multiprocessing import Pool @@ -713,5 +714,6 @@ def forward(self, text_df): results.append(("" if prompt is None else prompt) + query + " " + content) df = pd.DataFrame({"response": results}) - + # Make it slower + time.sleep(1) return df