fix: resolve hooks_cli.py merge conflict + add mine_global_lock tests
- Resolve UU conflict in hooks_cli.py: take develop/HEAD approach (mine synchronously via _mine_sync, then pass through unconditionally). _mine_sync already catches subprocess.TimeoutExpired — fixes Copilot #1. - Add tests/test_palace_locks.py: 4 tests covering mine_global_lock non-blocking semantics (acquire, second-acquire raises MineAlreadyRunning, reusable after release, release on exception) — fixes Copilot #4. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
committed by
Igor Lins e Silva
parent
91a60263e3
commit
7e18a70796
@@ -566,7 +566,9 @@ class ChromaBackend(BaseBackend):
|
||||
|
||||
if create:
|
||||
collection = client.get_or_create_collection(
|
||||
collection_name, metadata={"hnsw:space": hnsw_space}, **ef_kwargs
|
||||
collection_name,
|
||||
metadata={"hnsw:space": hnsw_space, "hnsw:num_threads": 1},
|
||||
**ef_kwargs,
|
||||
)
|
||||
else:
|
||||
collection = client.get_collection(collection_name, **ef_kwargs)
|
||||
@@ -613,7 +615,9 @@ class ChromaBackend(BaseBackend):
|
||||
ef = self._resolve_embedding_function()
|
||||
ef_kwargs = {"embedding_function": ef} if ef is not None else {}
|
||||
collection = self._client(palace_path).create_collection(
|
||||
collection_name, metadata={"hnsw:space": hnsw_space}, **ef_kwargs
|
||||
collection_name,
|
||||
metadata={"hnsw:space": hnsw_space, "hnsw:num_threads": 1},
|
||||
**ef_kwargs,
|
||||
)
|
||||
return ChromaCollection(collection)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user