-
Notifications
You must be signed in to change notification settings - Fork 3.2k
fix: honoring read_timeout at the cosmos client level #44472
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -107,6 +107,8 @@ async def _get_properties_with_options(self, options: Optional[dict[str, Any]] = | |
| kwargs[Constants.OperationStartTime] = options[Constants.OperationStartTime] | ||
| if "timeout" in options: | ||
| kwargs['timeout'] = options['timeout'] | ||
| if "read_timeout" in options: | ||
| kwargs['read_timeout'] = options['read_timeout'] | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Please use constant like Ideally, all other options should be replaced with constants, we can do that in separate PR. |
||
|
|
||
| return await self._get_properties(**kwargs) | ||
|
|
||
|
|
||
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
|
|
@@ -82,6 +82,14 @@ def _build_connection_policy(kwargs: dict[str, Any]) -> ConnectionPolicy: | |||||
| policy.RequestTimeout = kwargs.pop('request_timeout') / 1000.0 | ||||||
| else: | ||||||
| policy.RequestTimeout = kwargs.pop('connection_timeout', policy.RequestTimeout) | ||||||
|
|
||||||
| # Check if read_timeout is explicitly provided in kwargs (client-level) | ||||||
| if 'read_timeout' in kwargs: | ||||||
| policy.ReadTimeout = kwargs.pop('read_timeout') | ||||||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. should it be popped? WOuldn't this prevent any calls during the initialization to not have the timeouts? Same for the existing ones above
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Shouldn't we just use timeout values in |
||||||
| # Otherwise, check if policy has the new read_timeout property | ||||||
|
||||||
| # Otherwise, check if policy has the new read_timeout property | |
| # Otherwise, check if policy has the new read_timeout property |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry, I don't understand what scenario this is targeting. Is this if a customer adds a field to connection policy called read_timeout then we would grab it from there ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I agreed with Tomas, if read_timeout was set in policy by mistake, it is an user error and we shouldn't use it.
Also, what is proper behavior when users set ReadTimeout in policy and also provide read_timeout in kwargs? WIth current change, we overwrite one in policy to one in kwargs. Have you confirm if this was expected behavior?
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -1466,6 +1466,78 @@ def test_timeout_for_point_operation(self): | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| ) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| self.assertEqual(result['id'], 'test_item_1') | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| def test_request_level_timeout_overrides_client_read_timeout(self): | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| """Test that request-level read_timeout overrides client-level timeout for reads and writes""" | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| # Create container with normal client | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| normal_container = self.databaseForTest.create_container( | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| id='request_timeout_container_' + str(uuid.uuid4()), | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| partition_key=PartitionKey(path="/pk") | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| ) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| # Create test items | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| for i in range(5): | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| test_item = { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 'id': f'test_item_{i}', | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 'pk': f'partition{i}', | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 'data': f'test_data_{i}' | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| normal_container.create_item(test_item) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| # Create client with very short read timeout at client level | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| timeout_client = cosmos_client.CosmosClient( | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| url=self.host, | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| credential=self.masterKey, | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| read_timeout=0.001 # Very short timeout that would normally fail | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| ) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| print(f"test_crud got the client") | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| database = timeout_client.get_database_client(self.databaseForTest.id) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| container = database.get_container_client(normal_container.id) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| print(f"test_crud about to execute read operation") | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Comment on lines
+1493
to
+1496
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| print(f"test_crud got the client") | |
| database = timeout_client.get_database_client(self.databaseForTest.id) | |
| container = database.get_container_client(normal_container.id) | |
| print(f"test_crud about to execute read operation") | |
| database = timeout_client.get_database_client(self.databaseForTest.id) | |
| container = database.get_container_client(normal_container.id) |
Copilot
AI
Dec 18, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Debug print statement should be removed before merging. This statement appears to be leftover debugging code.
| print(f"test_crud got the client") | |
| database = timeout_client.get_database_client(self.databaseForTest.id) | |
| container = database.get_container_client(normal_container.id) | |
| print(f"test_crud about to execute read operation") | |
| database = timeout_client.get_database_client(self.databaseForTest.id) | |
| container = database.get_container_client(normal_container.id) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Shouldn't we also add a case when requests failed with the short timeout? That would show all other requests were successful because of request level timeouts.
Copilot
AI
Dec 18, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The timeout_client is not being properly closed. This could lead to resource leaks. Consider wrapping it in a try-finally block or using a context manager to ensure proper cleanup, similar to the async version which uses 'async with'.
| timeout_client = cosmos_client.CosmosClient( | |
| url=self.host, | |
| credential=self.masterKey, | |
| read_timeout=0.001 # Very short timeout that would normally fail | |
| ) | |
| print(f"test_crud got the client") | |
| database = timeout_client.get_database_client(self.databaseForTest.id) | |
| container = database.get_container_client(normal_container.id) | |
| print(f"test_crud about to execute read operation") | |
| # Test 1: Point read with request-level timeout should succeed (overrides client timeout) | |
| result = container.read_item( | |
| item='test_item_0', | |
| partition_key='partition0', | |
| read_timeout=30 # Higher timeout at request level | |
| ) | |
| self.assertEqual(result['id'], 'test_item_0') | |
| # Test 2: Query with request-level timeout should succeed (overrides client timeout) | |
| results = list(container.query_items( | |
| query="SELECT * FROM c WHERE c.pk = @pk", | |
| parameters=[{"name": "@pk", "value": "partition1"}], | |
| read_timeout=30 # Higher timeout at request level | |
| )) | |
| self.assertEqual(len(results), 1) | |
| self.assertEqual(results[0]['id'], 'test_item_1') | |
| # Test 3: Upsert (write) with request-level timeout should succeed | |
| upsert_item = { | |
| 'id': 'test_item_0', | |
| 'pk': 'partition0', | |
| 'data': 'updated_data' | |
| } | |
| result = container.upsert_item( | |
| body=upsert_item, | |
| read_timeout=30 # Higher timeout at request level | |
| ) | |
| self.assertEqual(result['data'], 'updated_data') | |
| # Test 4: Create (write) with request-level timeout should succeed | |
| new_item = { | |
| 'id': 'new_test_item', | |
| 'pk': 'new_partition', | |
| 'data': 'new_data' | |
| } | |
| result = container.create_item( | |
| body=new_item, | |
| read_timeout=30 # Higher timeout at request level | |
| ) | |
| self.assertEqual(result['id'], 'new_test_item') | |
| with cosmos_client.CosmosClient( | |
| url=self.host, | |
| credential=self.masterKey, | |
| read_timeout=0.001 # Very short timeout that would normally fail | |
| ) as timeout_client: | |
| print(f"test_crud got the client") | |
| database = timeout_client.get_database_client(self.databaseForTest.id) | |
| container = database.get_container_client(normal_container.id) | |
| print(f"test_crud about to execute read operation") | |
| # Test 1: Point read with request-level timeout should succeed (overrides client timeout) | |
| result = container.read_item( | |
| item='test_item_0', | |
| partition_key='partition0', | |
| read_timeout=30 # Higher timeout at request level | |
| ) | |
| self.assertEqual(result['id'], 'test_item_0') | |
| # Test 2: Query with request-level timeout should succeed (overrides client timeout) | |
| results = list(container.query_items( | |
| query="SELECT * FROM c WHERE c.pk = @pk", | |
| parameters=[{"name": "@pk", "value": "partition1"}], | |
| read_timeout=30 # Higher timeout at request level | |
| )) | |
| self.assertEqual(len(results), 1) | |
| self.assertEqual(results[0]['id'], 'test_item_1') | |
| # Test 3: Upsert (write) with request-level timeout should succeed | |
| upsert_item = { | |
| 'id': 'test_item_0', | |
| 'pk': 'partition0', | |
| 'data': 'updated_data' | |
| } | |
| result = container.upsert_item( | |
| body=upsert_item, | |
| read_timeout=30 # Higher timeout at request level | |
| ) | |
| self.assertEqual(result['data'], 'updated_data') | |
| # Test 4: Create (write) with request-level timeout should succeed | |
| new_item = { | |
| 'id': 'new_test_item', | |
| 'pk': 'new_partition', | |
| 'data': 'new_data' | |
| } | |
| result = container.create_item( | |
| body=new_item, | |
| read_timeout=30 # Higher timeout at request level | |
| ) | |
| self.assertEqual(result['id'], 'new_test_item') |
Copilot
AI
Dec 18, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The timeout_client is not being properly closed, and the container is not being cleaned up. This could lead to resource leaks. Consider wrapping the client in a try-finally block to ensure proper cleanup, and add container deletion at the end.
Copilot
AI
Dec 18, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The attribute name 'read_timeout' should be 'ReadTimeout' to match the naming convention used in line 1246 of test_crud_async.py and align with the ConnectionPolicy's property naming convention (ReadTimeout with capital R and T).
| connection_policy.read_timeout = 0.001 | |
| connection_policy.ReadTimeout = 0.001 |
Copilot
AI
Dec 18, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This try-except block that catches and prints the exception serves no testing purpose and should be removed. The actual test assertions are on lines 1644-1656, making this block redundant.
| try: | |
| container.read_item( | |
| item='test_item_0', | |
| partition_key='partition0' | |
| ) | |
| except Exception as e: | |
| print(f"Exception is {e}") |
Copilot
AI
Dec 18, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The timeout_client is not being properly closed, and the container is not being cleaned up. This could lead to resource leaks. Consider wrapping the client in a try-finally block to ensure proper cleanup, and add container deletion at the end.
| container.read_item( | |
| item='test_item_0', | |
| partition_key='partition0' | |
| ) | |
| except Exception as e: | |
| print(f"Exception is {e}") | |
| # Test 1: Point read operation should time out | |
| with self.assertRaises((exceptions.CosmosClientTimeoutError, ServiceResponseError)): | |
| container.read_item( | |
| item='test_item_0', | |
| partition_key='partition0' | |
| ) | |
| # Test 2: Query operation should time out | |
| with self.assertRaises((exceptions.CosmosClientTimeoutError, ServiceResponseError)): | |
| list(container.query_items( | |
| query="SELECT * FROM c WHERE c.pk = @pk", | |
| parameters=[{"name": "@pk", "value": "partition0"}] | |
| )) | |
| try: | |
| container.read_item( | |
| item='test_item_0', | |
| partition_key='partition0' | |
| ) | |
| except Exception as e: | |
| print(f"Exception is {e}") | |
| # Test 1: Point read operation should time out | |
| with self.assertRaises((exceptions.CosmosClientTimeoutError, ServiceResponseError)): | |
| container.read_item( | |
| item='test_item_0', | |
| partition_key='partition0' | |
| ) | |
| # Test 2: Query operation should time out | |
| with self.assertRaises((exceptions.CosmosClientTimeoutError, ServiceResponseError)): | |
| list(container.query_items( | |
| query="SELECT * FROM c WHERE c.pk = @pk", | |
| parameters=[{"name": "@pk", "value": "partition0"}] | |
| )) | |
| finally: | |
| # Ensure resources are cleaned up | |
| try: | |
| self.databaseForTest.delete_container(normal_container) | |
| except Exception: | |
| # Best-effort cleanup; ignore failures to avoid masking test errors | |
| pass | |
| try: | |
| timeout_client.close() | |
| except Exception: | |
| pass |
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -1112,6 +1112,165 @@ async def send(self, request, **kwargs): | |||||||||||||||||||||||||
| self.assertLess(elapsed_time, 7) # Allow some overhead | ||||||||||||||||||||||||||
| self.assertGreater(elapsed_time, 5) # Should wait at least close to timeout | ||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||
| async def test_request_level_timeout_overrides_client_read_timeout_async(self): | ||||||||||||||||||||||||||
| """Test that request-level read_timeout overrides client-level timeout for reads and writes """ | ||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||
| # Create container with normal client | ||||||||||||||||||||||||||
| normal_container = await self.database_for_test.create_container( | ||||||||||||||||||||||||||
| id='request_timeout_container_async_' + str(uuid.uuid4()), | ||||||||||||||||||||||||||
| partition_key=PartitionKey(path="/pk") | ||||||||||||||||||||||||||
| ) | ||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||
| # Create test items | ||||||||||||||||||||||||||
| for i in range(5): | ||||||||||||||||||||||||||
| test_item = { | ||||||||||||||||||||||||||
| 'id': f'test_item_{i}', | ||||||||||||||||||||||||||
| 'pk': f'partition{i}', | ||||||||||||||||||||||||||
| 'data': f'test_data_{i}' | ||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||
| await normal_container.create_item(test_item) | ||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||
| # Create async client with very short read timeout at client level | ||||||||||||||||||||||||||
| async with CosmosClient( | ||||||||||||||||||||||||||
| url=self.host, | ||||||||||||||||||||||||||
| credential=self.masterKey, | ||||||||||||||||||||||||||
| read_timeout=0.001 # Very short timeout that would normally fail | ||||||||||||||||||||||||||
| ) as timeout_client: | ||||||||||||||||||||||||||
| print(f"test_crud_async got the client") | ||||||||||||||||||||||||||
| database = timeout_client.get_database_client(self.database_for_test.id) | ||||||||||||||||||||||||||
| container = database.get_container_client(normal_container.id) | ||||||||||||||||||||||||||
| print(f"test_crud_async about to execute read operation") | ||||||||||||||||||||||||||
|
Comment on lines
+1139
to
+1142
|
||||||||||||||||||||||||||
| print(f"test_crud_async got the client") | |
| database = timeout_client.get_database_client(self.database_for_test.id) | |
| container = database.get_container_client(normal_container.id) | |
| print(f"test_crud_async about to execute read operation") | |
| database = timeout_client.get_database_client(self.database_for_test.id) | |
| container = database.get_container_client(normal_container.id) |
Copilot
AI
Dec 18, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Debug print statement should be removed before merging. This statement appears to be leftover debugging code.
| print(f"test_crud_async got the client") | |
| database = timeout_client.get_database_client(self.database_for_test.id) | |
| container = database.get_container_client(normal_container.id) | |
| print(f"test_crud_async about to execute read operation") | |
| database = timeout_client.get_database_client(self.database_for_test.id) | |
| container = database.get_container_client(normal_container.id) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Shouldn't it have timed out at this point ? This causes get database account calls.
Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should add a changelog entry.