Files
zeekay 75dd1132bd rename: zero ClickHouse — datastore_connect speaks X-Datastore-*
The wire protocol was the last holdout and it was not cosmetic: the Hanzo
Datastore server reads X-Datastore-User, and answers a request bearing
X-ClickHouse-User with 401. Verified against the live server, both directions.
So a client still sending the old headers is not merely off-brand, it cannot
authenticate over HTTP.

Everything else follows: types, dialects, error modules, docstrings and doc
links now name Datastore, and doc URLs point at docs.hanzo.ai/datastore rather
than the upstream vendor's site. Zero occurrences of the old name remain.

Still cut from the pinned upstream version, so behaviour is unchanged.
2026-07-26 11:06:05 -07:00

30 lines
835 B
Python

import threading
import pytest
from datastore_connect.driver import Client
from datastore_connect.driver.exceptions import ProgrammingError
from tests.integration_tests.conftest import TestConfig
def test_threading_error(test_config: TestConfig, test_client: Client):
if test_config.cloud:
pytest.skip('Skipping threading test in Datastore Cloud')
thrown = None
class QueryThread (threading.Thread):
def run(self):
nonlocal thrown
try:
test_client.command('SELECT randomString(512) FROM numbers(1000000)')
except ProgrammingError as ex:
thrown = ex
threads = [QueryThread(), QueryThread()]
for thread in threads:
thread.start()
for thread in threads:
thread.join()
assert 'concurrent' in str(thrown)