From f56d3a07b5a20a92be2e96ba9f4664c00e144c83 Mon Sep 17 00:00:00 2001 From: Agisilaos Kounelis Date: Fri, 25 Sep 2026 12:03:31 +0300 Subject: [PATCH 1/2] Drop the wall-clock limit from the bytes round-trip test The test failed whenever its body took over 2s, which a shared CI runner does now and then, while the round trip itself passed. It was left in to debug #1194; the test now checks only what it reads back. --- tiledb/tests/test_hypothesis.py | 27 --------------------------- 1 file changed, 27 deletions(-) diff --git a/tiledb/tests/test_hypothesis.py b/tiledb/tests/test_hypothesis.py index 6494f420da..c6b4c764f3 100644 --- a/tiledb/tests/test_hypothesis.py +++ b/tiledb/tests/test_hypothesis.py @@ -1,5 +1,3 @@ -import time - import hypothesis as hp import hypothesis.strategies as st import numpy as np @@ -18,14 +16,9 @@ @hp.settings(deadline=None, verbosity=hp.Verbosity.verbose) @hp.given(st.binary()) def test_bytes_npdf(checked_path, mode, data): - start = time.time() - uri = "mem://" + checked_path.path() - hp.note(f"!!! path '{uri}' time: {time.time() - start}") - array = np.array([data], dtype="S0") - start_ingest = time.time() if mode == "np": with tiledb.from_numpy(uri, array) as A: pass @@ -35,28 +28,8 @@ def test_bytes_npdf(checked_path, mode, data): # NOTE: ctx required here for mem:// tiledb.from_pandas(uri, df, sparse=False, ctx=tiledb.default_ctx()) - hp.note(f"{mode} ingest time: {time.time() - start_ingest}") - - # DEBUG - tiledb.stats_enable() - tiledb.stats_reset() - # END DEBUG - with tiledb.open(uri) as A: if mode == "np": np.testing.assert_array_equal(A.multi_index[:][""], array) else: tm.assert_frame_equal(A.df[:], df) - - hp.note(tiledb.stats_dump(print_out=False)) - - # DEBUG - tiledb.stats_disable() - - duration = time.time() - start - hp.note(f"!!! test_bytes_{mode} duration: {duration}") - if duration > 2: - # Hypothesis setup is (maybe) causing deadline exceeded errors - # https://github.com/TileDB-Inc/TileDB-Py/issues/1194 - # Set deadline=None and use internal timing instead. - pytest.fail(f"!!! {mode} function body duration exceeded 2s: {duration}") From 962ffa1d20208714aabdeb3ceafd47ab8d6fb62f Mon Sep 17 00:00:00 2001 From: Agisilaos Kounelis Date: Fri, 25 Sep 2026 12:03:31 +0300 Subject: [PATCH 2/2] Retry the TileDB release list download, and fail plainly if it can't be fetched file(DOWNLOAD) without STATUS leaves an empty file on failure and no error, so a dropped download surfaced later as "string sub-command STRIP requires two arguments". It is now retried three times and then reported with the URL and reason. --- cmake/DownloadTileDB.cmake | 31 ++++++++++++++++++++++++------- 1 file changed, 24 insertions(+), 7 deletions(-) diff --git a/cmake/DownloadTileDB.cmake b/cmake/DownloadTileDB.cmake index 34f93dc05d..d8a0ecd5d1 100644 --- a/cmake/DownloadTileDB.cmake +++ b/cmake/DownloadTileDB.cmake @@ -38,20 +38,37 @@ function(fetch_tiledb_release_list VERSION) set(VERSION latest) endif() + set(RELLIST_URL ${UPSTREAM_URL}/${VERSION}/releases.csv) if(EXPECTED_HASH) - file(DOWNLOAD - ${UPSTREAM_URL}/${VERSION}/releases.csv - ${CMAKE_CURRENT_BINARY_DIR}/releases.csv - SHOW_PROGRESS - EXPECTED_HASH ${EXPECTED_HASH} - ) + set(HASH_ARGS EXPECTED_HASH ${EXPECTED_HASH}) else() message(WARNING "Downloading release list without SHA checksum!") + endif() + + # A failed download leaves an empty file and no error, which surfaces + # later as an unrelated one, and a CI matrix fetches this from dozens of + # jobs at once. So a failure is retried, then reported as what it is. + set(ATTEMPTS 3) + foreach(ATTEMPT RANGE 1 ${ATTEMPTS}) file(DOWNLOAD - ${UPSTREAM_URL}/${VERSION}/releases.csv + ${RELLIST_URL} ${CMAKE_CURRENT_BINARY_DIR}/releases.csv SHOW_PROGRESS + ${HASH_ARGS} + STATUS DOWNLOAD_STATUS ) + list(GET DOWNLOAD_STATUS 0 DOWNLOAD_CODE) + list(GET DOWNLOAD_STATUS 1 DOWNLOAD_MESSAGE) + if(DOWNLOAD_CODE EQUAL 0) + break() + endif() + message(WARNING "Downloading ${RELLIST_URL} failed (attempt ${ATTEMPT} of ${ATTEMPTS}): ${DOWNLOAD_MESSAGE}") + if(ATTEMPT LESS ATTEMPTS) + execute_process(COMMAND ${CMAKE_COMMAND} -E sleep 5) + endif() + endforeach() + if(NOT DOWNLOAD_CODE EQUAL 0) + message(FATAL_ERROR "Could not download the TileDB release list from ${RELLIST_URL}: ${DOWNLOAD_MESSAGE}") endif() file(STRINGS