microsoft-agents-storage-cosmos 0.5.0.dev17__tar.gz → 0.5.0.dev19__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (16) hide show
  1. {microsoft_agents_storage_cosmos-0.5.0.dev17 → microsoft_agents_storage_cosmos-0.5.0.dev19}/PKG-INFO +2 -2
  2. {microsoft_agents_storage_cosmos-0.5.0.dev17 → microsoft_agents_storage_cosmos-0.5.0.dev19}/microsoft_agents/storage/cosmos/cosmos_db_storage.py +4 -4
  3. {microsoft_agents_storage_cosmos-0.5.0.dev17 → microsoft_agents_storage_cosmos-0.5.0.dev19}/microsoft_agents_storage_cosmos.egg-info/PKG-INFO +2 -2
  4. microsoft_agents_storage_cosmos-0.5.0.dev19/microsoft_agents_storage_cosmos.egg-info/requires.txt +3 -0
  5. microsoft_agents_storage_cosmos-0.5.0.dev17/microsoft_agents_storage_cosmos.egg-info/requires.txt +0 -3
  6. {microsoft_agents_storage_cosmos-0.5.0.dev17 → microsoft_agents_storage_cosmos-0.5.0.dev19}/LICENSE +0 -0
  7. {microsoft_agents_storage_cosmos-0.5.0.dev17 → microsoft_agents_storage_cosmos-0.5.0.dev19}/microsoft_agents/storage/cosmos/__init__.py +0 -0
  8. {microsoft_agents_storage_cosmos-0.5.0.dev17 → microsoft_agents_storage_cosmos-0.5.0.dev19}/microsoft_agents/storage/cosmos/cosmos_db_storage_config.py +0 -0
  9. {microsoft_agents_storage_cosmos-0.5.0.dev17 → microsoft_agents_storage_cosmos-0.5.0.dev19}/microsoft_agents/storage/cosmos/key_ops.py +0 -0
  10. {microsoft_agents_storage_cosmos-0.5.0.dev17 → microsoft_agents_storage_cosmos-0.5.0.dev19}/microsoft_agents_storage_cosmos.egg-info/SOURCES.txt +0 -0
  11. {microsoft_agents_storage_cosmos-0.5.0.dev17 → microsoft_agents_storage_cosmos-0.5.0.dev19}/microsoft_agents_storage_cosmos.egg-info/dependency_links.txt +0 -0
  12. {microsoft_agents_storage_cosmos-0.5.0.dev17 → microsoft_agents_storage_cosmos-0.5.0.dev19}/microsoft_agents_storage_cosmos.egg-info/top_level.txt +0 -0
  13. {microsoft_agents_storage_cosmos-0.5.0.dev17 → microsoft_agents_storage_cosmos-0.5.0.dev19}/pyproject.toml +0 -0
  14. {microsoft_agents_storage_cosmos-0.5.0.dev17 → microsoft_agents_storage_cosmos-0.5.0.dev19}/readme.md +0 -0
  15. {microsoft_agents_storage_cosmos-0.5.0.dev17 → microsoft_agents_storage_cosmos-0.5.0.dev19}/setup.cfg +0 -0
  16. {microsoft_agents_storage_cosmos-0.5.0.dev17 → microsoft_agents_storage_cosmos-0.5.0.dev19}/setup.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: microsoft-agents-storage-cosmos
3
- Version: 0.5.0.dev17
3
+ Version: 0.5.0.dev19
4
4
  Summary: A Cosmos DB storage library for Microsoft Agents
5
5
  Author: Microsoft Corporation
6
6
  License-Expression: MIT
@@ -15,7 +15,7 @@ Classifier: Operating System :: OS Independent
15
15
  Requires-Python: >=3.10
16
16
  Description-Content-Type: text/markdown
17
17
  License-File: LICENSE
18
- Requires-Dist: microsoft-agents-hosting-core==0.5.0.dev17
18
+ Requires-Dist: microsoft-agents-hosting-core==0.5.0.dev19
19
19
  Requires-Dist: azure-core
20
20
  Requires-Dist: azure-cosmos
21
21
  Dynamic: license-file
@@ -2,7 +2,7 @@
2
2
  # Licensed under the MIT License.
3
3
 
4
4
  from typing import TypeVar, Union
5
- from threading import Lock
5
+ import asyncio
6
6
 
7
7
  from azure.cosmos import (
8
8
  documents,
@@ -49,7 +49,7 @@ class CosmosDBStorage(AsyncStorageBase):
49
49
  self._container: ContainerProxy = None
50
50
  self._compatability_mode_partition_key: bool = False
51
51
  # Lock used for synchronizing container creation
52
- self._lock: Lock = Lock()
52
+ self._lock: asyncio.Lock = asyncio.Lock()
53
53
 
54
54
  def _create_client(self) -> CosmosClient:
55
55
  if self._config.url:
@@ -164,8 +164,8 @@ class CosmosDBStorage(AsyncStorageBase):
164
164
 
165
165
  async def initialize(self) -> None:
166
166
  if not self._container:
167
- with self._lock:
168
- # in case another thread attempted to initialize just before acquiring the lock
167
+ async with self._lock:
168
+ # in case another async task attempted to initialize just before acquiring the lock
169
169
  if self._container:
170
170
  return
171
171
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: microsoft-agents-storage-cosmos
3
- Version: 0.5.0.dev17
3
+ Version: 0.5.0.dev19
4
4
  Summary: A Cosmos DB storage library for Microsoft Agents
5
5
  Author: Microsoft Corporation
6
6
  License-Expression: MIT
@@ -15,7 +15,7 @@ Classifier: Operating System :: OS Independent
15
15
  Requires-Python: >=3.10
16
16
  Description-Content-Type: text/markdown
17
17
  License-File: LICENSE
18
- Requires-Dist: microsoft-agents-hosting-core==0.5.0.dev17
18
+ Requires-Dist: microsoft-agents-hosting-core==0.5.0.dev19
19
19
  Requires-Dist: azure-core
20
20
  Requires-Dist: azure-cosmos
21
21
  Dynamic: license-file
@@ -0,0 +1,3 @@
1
+ microsoft-agents-hosting-core==0.5.0.dev19
2
+ azure-core
3
+ azure-cosmos
@@ -1,3 +0,0 @@
1
- microsoft-agents-hosting-core==0.5.0.dev17
2
- azure-core
3
- azure-cosmos