@@ -81,8 +81,11 @@ def setUpClass(cls):
8181 raise ValueError ("VECTARA_API_KEY not found in environment variables or .env file" )
8282
8383 cls .client = Vectara (api_key = api_key )
84-
85- response = cls .client .corpora .create (key = "test-upload" , name = "test-upload" )
84+
85+ # Create corpus with unique name
86+ timestamp = int (time .time ())
87+ corpus_name = f"test-upload-{ timestamp } "
88+ response = cls .client .corpora .create (key = corpus_name , name = corpus_name )
8689 cls .corpus = response
8790
8891 def _get_test_file (self ):
@@ -163,16 +166,17 @@ def test_upload_with_larger_chunking(self):
163166 self .assertIsNotNone (document )
164167 self .assertGreater (document .storage_usage .bytes_used , 0 )
165168
169+ @unittest .skip ("Table extraction with GMFT can take longer than httpx default timeout - skip in CI" )
166170 @retry_on_exception (max_retries = 3 , retry_delay = 10 )
167171 def test_upload_with_table_extraction (self ):
168172 """Test file upload with table extraction."""
169173 test_file = self ._get_test_file ()
170-
174+
171175 with open (test_file , "rb" ) as file_content :
172176 file = (test_file .name , file_content , "application/pdf" )
173-
177+
174178 table_config = TableExtractionConfig (extract_tables = True , extractor = TableExtractorSpec (name = "gmft" ))
175-
179+
176180 document = self .client .upload .file (
177181 corpus_key = self .corpus .key ,
178182 file = file ,
0 commit comments